About the data intro

DataLoch brings together routinely collected health care data from primary and secondary care in the Lothian region covering a population of 900,000 people. These data enable researchers to answer important questions about how the wellbeing of people could be improved, and support service-management decisions within the NHS.

There are many examples of how health data research has delivered insights to help solve challenging health problems, including diagnosing rare diseases, improving the performance and equity of care, identifying diseases early, and assessing the effectiveness of health services. Data extracts approved for researcher access are minimised, which means we provide no more data than the minimum needed to fulfil the specific approved application.

Data Security


Preparing the data

DataLoch works with data in several ways, including:

  • collaborating with clinicians to improve the data quality;
  • linking datasets to enable broad insights;
  • translating data into common standard definitions; and
  • maintaining a high-quality metadata catalogue with the support of NHS expertise.


Accessing the data we host

The below datasets are linkage ready. If you don’t see the data for your research here, please contact us to either request access to our complete Metadata Catalogue or to start a discussion about bringing the relevant data together to support your proposal development. 

Connect with Us

Laptop on a desk with some printed sheets containing graphs and charts.

About the data - lower section

DataLoch Registries

A DataLoch Registry offers a theme-specific database of South-East Scotland residents, usually defined by one or more related conditions or diseases. The DataLoch team collaborates with the theme-specific academic and clinical experts to process the raw data, fully understand the data and improve reliability, to address inconsistencies and make them research-ready.  


  Focused on South-East Scotland residents with acute and chronic respiratory conditions, specifically COPD (Chronic Obstructive Pulmonary Disease) and ILD (Interstitial Lung Disease). This registry aligns with respiratory registries hosted in England (CPRD) and Wales (SAIL Databank), thereby offering significant opportunities for researchers wishing to explore questions across the three nations.


  A combination of COVID-19-related data, such as laboratory test results, symptoms, treatments, complications, vaccinations and hospitalisation outcomes.


Demographic information

DataLoch Demographics

  Information about the statistical characteristics of people resident or using health care services in the Lothian region. DataLoch combines information from different sources to improve the quality of data.

Scottish Index of Multiple Deprivation (SIMD)

  Summary data capturing the relative deprivation status of geographic areas of Scotland. Including this information in research takes into account the relationships between living in specific areas and health.


DataLoch-curated datasets


  A collection of lifestyle information, risk scores and measurements that can impact health. DataLoch processes data from many sources to improve the reliability and relevance of data for research.

Health Conditions

  The DataLoch team has, where possible, combined the codes used by GPs, hospital/facilities, and national records to summarise patient conditions, based on the defined standards from the HDR UK Phenotype Library.


Primary care datasets

GP Registrations and Demographics


  Information on GP registrations in the Lothian region, including population statistics.

GP Clinical Events


  Codes used by GPs to summarise such things as symptoms, examinations, observations, test results, screenings, vaccines, operations, therapeutic procedures, and diagnoses, as well as administrative items such as recording reports.

In-hours GP Activity


  All patient encounters with GP practices, either indirect or direct.


Secondary care datasets

Electronic Health Records

Hospital Demographics


  Information about the characteristics of people using NHS Lothian hospitals or facilities.

Hospital Emergency Attendances


  Arrival and discharge details from all Emergency Attendances in NHS Lothian, covering Accident and Emergency departments, Minor Injury units, and Obstetrics Triage. Includes dates, times, incident circumstances, triage details, and referral and discharge information.

Hospital Admissions and Discharges


  Information about admissions and discharges from any NHS Lothian hospital or facility, including dates, times, specialties involved, and reason for admission. 

Hospital Patient Movements and Transfers


  These datasets capture patient journeys through NHS Lothian hospitals or facilities.

Critical Care


  Data relating to patients requiring critical care treatment (i.e. in intensive care and high-dependency units), such as admissions, severity of illness, organ-support treatments and therapies, and outcomes of treatment.
Scottish Morbidity Records

Outpatient Attendances 

Scottish Morbidity Record (SMR00)

  Information about outpatient attendances at any NHS Lothian hospital or facility, including dates, times, conditions and procedures.

General and Acute Services

Scottish Morbidity Record (SMR01)

  Information about general and acute attendances at any NHS Lothian hospital or facility, including dates, times, conditions and procedures.

Maternity Services 

Scottish Morbidity Record (SMR02)

  Information about maternity inpatient and day cases at any NHS Lothian hospital or facility, including dates, times, conditions and procedures.

Mental Health Services

Scottish Morbidity Record (SMR04)

  Patient records relating to all inpatients and day cases admitted to, and discharged from, mental health facilities in NHS Lothian.

Scottish Cancer Registry 

Scottish Morbidity Record (SMR06)

  Record of cancer episodes at any NHS Lothian hospital or facility. Each record covers a separate primary cancer registration and comprises patient data, diagnosis, pathology, staging, and treatment information. Also includes dates, primary and secondary cancer, and any information from a corresponding death record.


Diagnostic tests and investigations

Laboratory results


  Covering both primary and secondary care, this includes laboratory test results undertaken in NHS Lothian’s haematology, biochemistry, and microbiology labs.

Pulmonary Function Tests


  Lung function tests to support the diagnosis and treatment of lung conditions.

Cardiac Surgeries and Procedures


  Information about all cardiac (heart) surgeries and less-invasive procedures completed within the NHS Lothian region.



Systemic Anti-Cancer Therapy (SACT)


  A South-East Scotland regional dataset taken from the ChemoCare prescribing system. Includes chemotherapy, immunotherapy, and other drug treatments for cancer.



  A South-East Scotland regional dataset taken from the AIRA radiotherapy planning and delivery system. Includes dosing, fractionation, and related metadata and images.

National Cancer Quality Audit and Cancer Registration datasets

  Includes a number of tumour-specific datasets based on relevant data collated from across Scotland. Within each of these datasets are details such as tumour type, recurrence, treatments, and staging.


Linked national datasets

Cause of death

National Records of Scotland

  Nationally curated data showing the date and cause(s) of death.


Public Health Scotland

  Summary of prescriptions that are dispensed in the community (i.e. not within hospitals) throughout the NHS Lothian region.



About the data last paragraph

GRAPHIC - How we make data research ready