View
3
Download
0
Category
Preview:
Citation preview
No conflicts of interest
Note: All results have been modified from their actual values for the purpose of this presentation
The Complete Journey from EHR Data to Actionable Insights
orHow to communicate with your data analyst
Jordan Swartz, MD, MADirector, Clinical Informatics, Ronald O. Perelman Department of Emergency MedicineAssociate Professor, New York University School of Medicine
JordanLSwartz@gmail.com
EHR Data to Actionable Insights
From clinical question to visualization1. Formulate the question in detail
2. Determine the data needed to answer the question
3. Query the database
4. Analyze the data
5. Visualize the analysis
1. Formulate the question in detail• 1. Ask the general question
• Is my emergency department prescribing opioids appropriately?
• 2. Determine what you want to measure• Departmental Rx rate, individual provider rates, rates over time
• 3. Define the population• Numerator: Number of patients with an opioid-sparing diagnosis • Denominator: Number of patients prescribed an opioid in 2016-18 • Denominator exclusions: Admitted, peds, CT/MRI
• 4. Formulate the question in detail• What are the opioid Rx rates both overall and over time at both the departmental
and individual levels for patients who presented to the ED from 2016-2018 with opioid-sparing diagnoses?
2. Consider the data needed to answer the question• Encounter Number• MRN• Patient name• Age• ED arrival time• ED disposition time• ED disposition• ED diagnosis• Prescription information
• Drug or drug category• Quantity
• Prescriber (if work without PAs/Residents)• Attending (if work with PAs/Residents• Imaging orders
3. Query the (relational) database
Encounters Table
Patient Table
Encounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Encounters
Patient
Encounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Visit_type Visit_Name
1 Office Visit
2 Laboratory
3 Emergency
Visit
A Gentle Introduction to SQL
A Gentle Introduction to SQL• SELECT
• Specifies the data
• FROM• Specifies the tables
• Join• Specifies joining the tables
• WHERE• Specifies the filters
Encounters
Patient
VisitEncounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Visit_type Visit_Name
1 Office Visit
2 Laboratory
3 Emergency
INPUT
Select Encounter_ID, MRNFROMEncounters
Encounter_ID MRN
745443 19555
745442 15432
745441 13221
Output
Encounters
Patient
VisitEncounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Visit_type Visit_Name
1 Office Visit
2 Laboratory
3 Emergency
INPUT
Select Encounter_ID, MRN, NameFROMEncounters
inner join Patient on Encounters.MRN = Patient.MRN
Encounter_ID MRN Name
745443 19555 John Smith
745442 15432 Jane Smith
745441 13221 John Donald
Output
Encounters
Patient
VisitEncounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Visit_type Visit_Name
1 Office Visit
2 Laboratory
3 Emergency
Select Encounter_ID, Name, Visit_NameFROMEncounters
inner join Patient on Encounters.MRN = Patient.MRNinner join Visit on Encounters.Visit_type = Visit.Visit_type
Encounter_ID Name Visit_Name
745443 John Smith Office Visit
745442 Jane Smith Laboratory
745441 John Donald
Emergency
Encounters
Patient
VisitEncounter_ID Arrival_date MRN Visit_type Disposition_code
745443 05/02/2019 19555 3 14
745442 05/02/2019 15432 1 18
745441 05/01/2019 13221 2 22
MRN Name Date_of_birth Ethnicity Marital_status
19555 John Smith 04/25/1954 11 2
15432 Jane Smith 01/08/1978 3 1
13221 John Donald 11/12/1990 6 3
Visit_type Visit_Name
1 Office Visit
2 Laboratory
3 Emergency
Select Encounter_ID, Name, Visit_NameFROMEncounters
inner join Patient on Encounters.MRN = Patient.MRNinner join Visit on Encounters.Visit_type = Visit.Visit_type
WHERE Visit_Name = “Emergency”
Encounter_ID Name Visit_Name
745441 John Donald
Emergency
Encounter ID,Patient_Name,Primary_CC,Primary_DX,Age,ArrivalInstant,DepartureInstant,Attending,Department_Name,Care_Area,Prescription_Name,Prescription_Quantity,"CT?","MRI?",MED,MED_DATE,MED_CLASS
attendingproviderfact.FirstInEncounter IN ( '1' )andEdVisitProfileDim.EdDisposition = 'Discharge‘andedvisitfact.UnderObservation = '0‘andProceduredim.Category IN ( 'IMG CT, 'IMG MRI’)andProcedureOrderProfileDim.status <> 'Canceled‘andMedicationdim.PharmaceuticalClass like '%opioid%‘andOrdereddttm < evf.DepartureInstantandTherapeuticClass = 'Analgesics'
SELECT WHEREEdVisitFactPatientDimChiefComplaintDimDiagnosisDimAttendingProviderFactDepartmentDimEdVisitProfileDimCareareadimMedicationOrderFactMedicationdimProcedureDimProcedureOrderFact
FROM
Opioid Query
4. Analyze the dataDepartmental Rx rate, individual provider rates, rates over time
Popular Tools:• Excel
• R• Python
• Tableau• Qlikview
• SAS• STATA
5. Visualize the analysis
Tableau Demo
Group Practice Session
Recommended