Data files

This publication contains the following data files for a rolling five-year trend, broken down into quarters. Please note, only acute hospitals are included in the data files. Only acute specialties are included in the inpatient and day case files. For further information please see the methods section.

Outpatient Activity

Data on outpatient appointments is for consultant-led activity only. These data files are split by location (NHS board of treatment/residence, hospital and council area), specialty, age and sex, and SIMD for new and Did Not Attend (DNA) appointments; and split by specialty and NHS board of treatment for return and total appointments.

Outpatients by NHS Board of residence to September 2021

Outpatients by NHS Board of treatment to September 2021

Outpatients Cross boundary flow to September 2021

See outpatient activity variables

The residence data files relate to activity by NHS Board of residence. The treatment data files relate to activity by NHS Board of treatment. Outpatient residence files only contain data for new outpatients as the ISD(S)1 data source for return outpatients does not contain residence information. ISD(S)1 also does not record information on the age or sex of patients, nor the deprivation of the area in which they live.

Inpatient and Day Case Activity

These data files are split by location (NHS Board of treatment/residence, hospital and council area), age and sex, and SIMD for both episodes and stays. Specialty breakdowns are split by episodes and spells, rather than stays. For more information, please see the methodology section. Measures include emergency admissions, elective admissions, inpatients, day cases, total inpatients and day cases, transfers, and not specified.

Inpatient and day cases by NHS board of residence to September 2021

Inpatient and day cases by NHS board of treatment to September 2021

Inpatient and day case cross boundary flow to September 2021

See inpatient and day case activity variables

The residence data files relate to activity by NHS Board of residence. The treatment data files relate to activity by NHS Board of treatment.

Hospital Beds to September 2021

The ISD(S)1 data source for beds does not contain residence information. ISD(S)1 also does not record information on the age or sex of patients, nor the deprivation of the area in which they live. For further information please see the methods section​.

Due to the way specialties are recorded for beds data, it is not possible to use the PHS Beds statistics to estimate the total number of beds which are available for use for different services and/or departments. For example, selecting the paediatric specialty grouping will only provide a partial picture of the staffed beds that are used for children’s services. This is because many beds used for children are not recorded under paediatric specialties and are instead recorded under more specific specialties, e.g. Haematology, Neurology, and Respiratory Medicine. Furthermore, the specialty recorded for a bed depends partly on what the patient is being treated for, so for some wards the mix of specialties may change over time. Similarly, analysis of the Accident & Emergency specialty bed usage will only provide inpatient and day case information on beds within the Accident & Emergency specialty e.g. Accident & Emergency ward beds and observation beds staffed overnight. It will not provide information on the services/capacity within Accident & Emergency departments as a whole.

See hospital beds variables

File variables

Generic Variables
Variable name Definition Format Missing value
quarter_date Final date of the quarter Date (dd/mm/yy) NA
quarter_name Quarter period in text format Text (mmm – mmm-yy) NA
hb_code NHS Board code: Either the 9 digit NHS Board code or "scot" for Scotland. For the residence data files, the NHS Board code and name is in relation to the NHS Board of residence. For the treatment data files, the NHS Board code and name is in relation to the NHS Board of treatment. Text NA
hb_name NHS Board name Text NA
loc_code Location code: Either the 5 digit hospital code; 9 digit NHS Board or council code; or “scot” for Scotland Text NA
loc_name Location name Text NA
specialty 2 digit specialty code Text NA
spec_name Specialty name Text NA
sex_age Sex (Male or Female) and 10 year age bands combined Text NA
simd Quintiles of Scottish Index of Multiple Deprivation (1 - most deprived, 5 - least deprived) Number NA
hbtreat_currentdate NHS Board of treatment code Text NA
hbtreat_name NHS Board of treatment name Text NA
hbres_currentdate NHS Board of residence code Text NA
hbres_name NHS Board of residence name Text NA
attendances Number of attendances Number NA
boundary_ind Indicates whether the NHS Board of treatment is the same as the NHS Board of residence (0 - no, 1 - yes) Number NA

 

Outpatients-specific variables
Variable name
Definition
Format
Missing value
appt_type Outpatient appointment type: New, Return, All Appointments (total of 'New' + 'Return') or DNA Text NA
count Number of appointments Number NA
rate Only available for DNAs, i.e. DNA rate. DNA rates are calculated from new appointments only and are presented as a percentage of the total number of outpatient appointments Number NA

 

Inpatients-specific variables
Variable name
Definition
Format
Missing value
measure Inpatient/admissions type: Elective Inpatients; Emergency Inpatients; Transfers; Not Specified; All Day cases; All Inpatients; All Inpatients and Day cases Text NA
eps Number of episodes Number

NA

spells Number of specialty spells Number

NA

stays Number of stays Number NA
los Total length of stay/spell Number NA
avlos Average length of stay/spell Number NA

Beds-specific variables
Variable name Definition Format Missing value
aasb Quarterly available staffed bed days i.e. number of available staffed bed days over the quarter Number NA
tobd Quarterly occupied bed days i.e. total number of occupied bed days over the quarter Number NA
asb Daily Average available staffed beds i.e. average number of available staffed beds per day Number NA
aob Daily Average occupied beds i.e. average number of occupied beds per day Number NA
p_occ Percentage (%) occupancy Number NA

 

Last updated: 21 March 2024
Was this page helpful?