Abstract
To demonstrate a process of calculating the maximum potential morphine milligram equivalent daily dose (MEDD) based on the prescription Sig for use in quality improvement initiatives. To calculate an opioid prescription’s maximum potential Sig-MEDD, we developed SQL code to determine a prescription’s maximum units/day using discrete field data and text-parsing in the prescription instructions. We validated the derived units/day calculation using 3000 Sigs, then compared the Sig-MEDD calculation against the Epic-MEDD calculator. Of the 101 782 outpatient opioid prescriptions ordered over 1 year, 80% used discrete-field Sigs, 7% used free-text Sigs, and 3% used both types. We determined units/day and calculated a Sig-MEDD for 98.3% of all the prescriptions, 99.99% of discrete-Sig prescriptions, and 81.5% of free-text-Sig prescriptions. Analyzing opioid prescription Sigs to determine a maximum potential Sig-MEDD provides greater insight into a patient’s risk for opioid exposure.
Keywords: opioid, pain, population health, morphine, prescription
INTRODUCTION
In response to the opioid crisis, health systems have increased efforts to analyze opioid prescriptions. In this paper, we describe a method for determining maximum units per day from prescription instructions (Sigs) within the electronic health record (EHR) to calculate a maximum potential morphine equivalency (Sig-morphine milligram equivalent daily dose [MEDD]). Our aim was to develop a metric that would aid in quantifying the daily opioid exposure a patient might experience based on the Sig. Studying patient populations using this metric could allow us to identify the influence of patient instructions on opioid overdose, addiction, and potential misuse.
Most pharmacoepidemiology studies utilize Defined Daily Dose (DDD) or Morphine Milligram Equivalents (MME). DDD tries to estimate the expected daily dose; however, we were interested in determining the maximum daily dose exposure based on Sig instructions.1 MME provides us with the total morphine equivalency exposure on a total prescription level. This method, however, does not help us understand the daily exposure risk. Determining daily exposure is often dependent on knowing the days’ supply, which is often omitted, and may underestimate potential exposure compared to the Sig, especially for “as needed” medications.1,2
There have been several efforts to parse out discrete variables from free-text Sigs or clinician encounter notes using methods, programs, or manual abstraction—the latter which is neither feasible nor preferred for real-time health system data needs.3,4 Several research groups have developed Natural Language Processing applications (PredMED, MedEx, and MedXN) that extract prescription information from the Sig, clinical notes, medication reconciliation notes.5–8 We chose the SQL free-text abstraction method as a single system to extract data, convert Sigs, and make calculations.
Previous published MEDD calculations rely primarily on claims data, retail prescription data, or retrospective clinical data; to our knowledge, there are not published papers detailing the calculation of an efficient MEDD.9–12 In these studies, the MEDD is calculated by summing the total daily amount of opioid prescription (the product of frequency, dose, and strength) and converting by a conversion factor.13 However, recent studies using MEDD data for dashboards do not detail text-parsing methods for free-text Sigs, either relying on discrete field or making assumptions about the MEDD based on the days’ supply.
Our objectives were as follows: (1) to demonstrate the feasibility of using a Sig to determine units/day for calculating Sig-MEDD and (2) to illustrate 2 validation methods. While we focused on opioid prescriptions, the Sig data extraction could be used for other medications.
METHODS
Setting
Our academic health system includes an 886-bed tertiary care hospital and a 133-bed community hospital. The system also includes various multispecialty, primary care, and urgent care clinics. From 2017 to 2018, the health system had 794 312 outpatient visits, 56 636 inpatient admissions, 123 161 emergency department (ED) admissions, and 277 023 inpatient days. In 2017, the net patient service revenue by payer source was Medicare (25%), Medicaid (5%), Health Maintenance Organization/Preferred Provider Organization (64%), and self-pay/other (6%).14
Data source
Data were extracted from our organization’s Epic EHR’s Clarity database using Oracle SQL. We used the Centers for Disease Control and Prevention (CDC) opioid data files which contain morphine equivalent conversion factors, strength per unit (spu), and a National Drug Code for the available nonintravenous opioid medication based on formulation.13,15 For methadone, the CDC table provides a morphine equivalency for the lowest dose. However, methadone’s morphine equivalency must be adjusted based on the total daily dose: the higher the daily dose and the higher the conversion factor. We developed logic to calculate the daily dose and applied the appropriate conversion factor. For buprenorphine films, we used a regular expression to extract the spu and assigned a morphine equivalency conversion factor (MECF) of 12.6 based on Centers for Medicare and Medicaid Services (CMS) conversion factors.16
The date range for prescriptions was limited to prescriptions ordered between July 1, 2017 and June 30, 2018. We included all outpatient opioid prescriptions, including discharge medications, ED visit discharge prescriptions, or ambulatory care prescriptions. We excluded intravenous medications from our analysis. We excluded medications discontinued within 3 days of ordering. The study was deemed exempt from Institutional Review Board review.
Method development
Calculating a MEDD requires 3 components: (1) the number of units per day; (2) the medication’s spu; and the (3) MECF. The spu and conversion factor are based on the medication, administration route (eg, transdermal), and form prescribed.
The prescription’s units per day can be derived from the units/dose and doses/day found in the prescription Sig. We demonstrate the equation for calculating an estimated MEDD below:
We detail the process of calculating a Sig-MEDD in Figure 1.
Number of units per day
Through an iterative process, we identified the various ways opioid prescription Sigs were written by providers within our system. We first separated the Sig into both its discrete and free-text components. We developed logic to extract the doses per day and units per dose from the discrete fields. We used a combination of prescribing knowledge and a review of the data to identify common Sig patterns to develop string-matching case statements that translate the number of units per dose and the number of doses per day into discrete fields (see Table 1) (see Supplementary Appendix S1 for the SQL code).
Table 1.
Free-text phrase | Maximum potential units per dose | Maximum potential doses per day | Strength per unit | Conversion factor | Total maximum daily dose |
---|---|---|---|---|---|
Hydrocodone 5/325 “Take 1–2 tablets every 4–6 h” | 2 | 6 | 5 | 1 | 60 MEDD |
Hydrocodone 10/325 “Take 2 tables twice daily” | 2 | 2 | 5 | 1 | 20 MEDD |
Oxycodone 30 mg “Take 1–2 tablets bid” | 2 | 2 | 30 | 1.5 | 180 MEDD |
Abbreviation: MEDD: morphine milligram equivalent daily dose.
When prescriptions had ranges of dosages or frequencies in either discrete or free-text form, we determined the maximum units per dose and maximum doses per day. When a Sig did not have a value for doses/day or units/day based on discrete or free-text components, the method entered a null value, which allowed us to flag those prescriptions for review and continue to improve our logic (see Figure 2).
Validation
Validation of units per day
We selected 3000 unique Sigs for review and validation. Two analysts reviewed 1500 Sigs and 1 informaticist reviewed all 3000 Sigs. We used consensus to resolve differences between raters. The validation process consisted of manually reviewing prescriptions using the Sigs to derive the maximum units/day and compared against our SQL-derived units/day. Given the high skewness of the units/day, we log-transformed the units/day calculated by both methods. We plotted a Bland–Altman scatterplot (see Supplementary Appendix), which examines the quantification of the agreement between 2 continuous measurements by using the mean difference and constructing limits of agreement based on the difference.17,18 We assessed agreement in units/day only when both methods reported results. We also conducted a 1-sample t-test to examine the mean difference and 95% confidence intervals (CIs) of units per day between the 2 methods.17
Validation of MEDD
The Epic-MEDD calculator went live within our health system on May 4, 2018 and back-dated past prescriptions with the Epic-MEDD. We compared the Sig-MEDD to the Epic-MEDD across both the discrete field and free-text prescriptions. Given the high skewness of MEDD distributions for both methods, we log-transformed the MEDDs calculated by both methods. We plotted a Bland–Altman scatterplot to look for systematic variation between the mean of the 2 differences.18 We analyzed the mean difference in MEDDs only when both methods reported results. We conducted a 1-sample t-test to examine the mean difference and the 95% CIs of MEDDs between the 2 methods.18
RESULTS
Descriptive statistics
From July 1, 2017 to June 30, 2018, 101 782 opioid prescriptions were written within our organization using 7362 unique Sigs. Of these prescriptions, 81.5% were written as “prn” or “as needed” prescriptions, 9.2% were written as free-text Sigs and 13.6% of Sigs contained a range for either the units per dose or doses per day.
Our method calculated a Sig-MEDD for 98.3% of prescriptions, 99.99% of discrete Sigs, and 81.5% of free-text Sigs. We were unable to calculate a Sig-MEDD for 1765 prescriptions and 790 distinct Sigs. For these prescriptions, we found Sigs with time-based directions, non-English sigs, and missing information.
The majority of opioid prescriptions in the system were for short-acting opioids, including hydrocodone (45.63%), oxycodone (24.33%), and tramadol (15.42%). There were fewer recorded prescriptions of long-acting or sustained-released preparations of oxycodone (2.79%) and morphine (1.62%).
Validation of units per day
Three thousand Sigs were randomly selected for manual review and units per day calculations. Four hundred and forty were excluded because either our method or reviewers were not able to determine units/day. The remaining 2560 Sigs account for 35% of all Sigs and 43 728 (43%) of the prescriptions.
The manual review matched the SQL-derived units/day for 2426 (94.8%) Sigs, which accounted for 42 622 of the prescriptions (97.5%). The units/day differed for 134 Sigs (5.2%), which accounted for 1106 of the prescriptions (2.5%) (see Figure 3). We found a mean difference of 0.003 between the log-transformed units/day from both methods (95% CI: −0.0003 to 0.0055), which was not statistically significant (P = .08) (see Supplementary Appendix S3 for the Bland–Altman plot).
The manually derived units/day differed from the text-mined units/day for a several reasons. We found a small number of nontranslatable Sigs. Second, our method examines the prescription Sig including the discrete and free-text fields. We aimed to maximize both the units/dose and doses/day across the entire Sig, which may overestimate the units/day because each component could potentially be derived from either the discrete portion of the Sig or the free-text portion of the Sig. In Table 2, we present examples of Sigs with different units/day from our validation process.
Table 2.
Example | SLQ method units/day | Manually reviewed units/day |
---|---|---|
“Take 1 tablet by mouth every 4 h as needed. Or 2 tabs every 6 h as needed for pain” | 12 | 8 |
“Take 1 tablet by mouth daily. May take 1–2 extra” | 1 | 3 |
“1 tablet 2 times daily and at nighttime as needed” | 2 | 3 |
Validation of MEDDs
Our method calculated a Sig-MEDD for 98.3% of prescriptions, 99.99% of discrete Sigs, and 81.5% of free-text Sigs. Epic calculated a MEDD for 89.2% of all prescriptions, 98.2% of discrete Sigs, and 0% of free-text Sigs. Comparing the same prescription across both methods revealed that they were within 2 MEDDS of each other 96.07% of the time.
Of the 101 915 prescriptions, we calculated MEDDs by both methods for 90 427 prescriptions, or 88.7%. Of these 90 427 prescriptions, our algorithm resulted in an average MEDD of 45 with a standard deviation (SD) of 48. The Epic-MEDD calculation had an average MEDD of 45 with an SD of 61. The correlation between the MEDDs calculated by both methods was 0.98 (see Supplementary Appendix S2). The mean difference of the log-transformed MEDDs calculated by both methods was −0.01 (95% CI: −0.0113 to −0.0105). Although the t-test was statistically significant given the large sample size (P < .001), the mean difference was small and not clinically significant. The Bland–Altman scatterplot showed no systematic variation between the mean of the 2 differences (see Supplementary Appendix S4).
DISCUSSION
We were able to calculate a Sig-MEDD for nearly 90% of free-text Sigs, which allows for population health analytics of more prescriptions. A Bland–Altman analysis between the Sig-MEDD and the Epic-MEDD reveals that the methods are comparable. Our method estimates a Sig-MEDD for a larger portion of prescriptions because we incorporate free-text instructions. Our method calculated a Sig-MEDD for 98.3% of prescriptions, 99.99% of discrete Sigs, and 81.5% of free-text Sigs. Our Sig-MEDD method performed equally well or better than other published text-parsing methods such as PredMED, MedEx, and MedXN on prescription extraction,5 with similar levels of precision.
We envision several uses of the Sig-MEDD, including: (1) understanding prescribing behavior at the Sig level, which help design interventions to modify prescribing behavior, (2) identifying a more accurate picture of an individual’s potential daily exposure, therefore helping identify risk for dependence or accidental overdose, and (3) using the Sig-MEDD to examine the role of different levels of daily opioid exposure on dose escalation.2
Limitations
We only used data from our EHR system, which does not include pharmacy fill data, claims data, or prescriptions documented within provider notes. Although the SQL code may not be generalizable to institutions that do not use Epic, the approach may be useful after a site analyzes their Sigs.
CONCLUSION
Using Sig-MEDD to determine a maximum potential MEDD provides greater insight into a patient’s risk for opioid exposure. Our Sig-MEDD approach is generalizable to other institutions in that we parsed the majority of free-text Sigs (81.5%); clinicians at other institutions are likely to use similar free-text Sigs.
SUPPLEMENTARY MATERIAL
Supplementary material is available at Journal of the American Medical Informatics Association online.
FUNDING
Michelle S. Keller was supported by NIH/National Center for Advancing Translational Science (NCATS) UCLA CTSI grant number TL1TR000121 during this project.
Conflict of interest statement. None declared.
Supplementary Material
REFERENCES
- 1. Nielsen S, Gisev N, Bruno R, et al. Defined daily doses (DDD) do not accurately reflect opioid doses used in contemporary chronic pain treatment. Pharmacoepidemiol Drug Saf 2017; 265: 587–91. [DOI] [PubMed] [Google Scholar]
- 2. Chua K-P, Brummett CM, Waljee JF.. Opioid prescribing limits for acute pain: potential problems with design and implementation JAMA 2019; 3217: 643–4. [DOI] [PubMed] [Google Scholar]
- 3. Liu H, Burkhart Q, Bell DS.. Evaluation of the NCPDP structured and codified Sig format for e-prescriptions. J Am Med Inform Assoc 2011; 185: 645–51. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 4. Rajeevan N, Niehoff KM, Charpentier P, et al. Utilizing patient data from the veterans administration electronic health record to support web-based clinical decision support: informatics challenges and issues from three clinical domains. BMC Med Inform Decis Mak 2017; 171: 111.. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 5. Wang Y, Steinhubl SR, Defilippi C, et al. Prescription extraction from clinical notes: towards automating EMR medication reconciliation. AMIA Summits Transl Sci Proc 2015; 2015: 188–93. [PMC free article] [PubMed] [Google Scholar]
- 6. Sohn S, Clark C, Halgrim SR, Murphy SP, Chute CG, Liu H.. MedXN: an open source medication extraction and normalization tool for clinical text. J Am Med Inform Assoc 2014; 215: 858–65. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 7. Xu H, Stenner SP, Doan S, Johnson KB, Waitman LR, Denny JC.. MedEx: a medication information extraction system for clinical narratives. J Am Med Inform Assoc 2010; 171: 19–24. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 8. Desai BR. Design and Evaluation of an Algorithmic Parser for Free-Text Prescription Data in an Ambulatory Electronic Health Record. Portland, Oregon: Oregon Health & Science University; 2008. [Google Scholar]
- 9. Guy GP Jr, Zhang K, Bohm MK, et al. Vital signs: changes in opioid prescribing in the United States, 2006-2015. MMWR Morb Mortal Wkly Rep 2017; 6626: 697–704. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 10. Morasco BJ, Duckart JP, Carr TP, Deyo RA, Dobscha SK.. Clinical characteristics of veterans prescribed high doses of opioid medications for chronic non-cancer pain. Pain 2010; 1513: 625–32. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 11. Bohnert AB, Valenstein M, Bair MJ, et al. Association between opioid prescribing patterns and opioid overdose-related deaths. JAMA 2011; 30513: 1315–21. [DOI] [PubMed] [Google Scholar]
- 12. Lin LA, Bohnert ASB, Kerns RD, Clay MA, Ganoczy D, Ilgen MA.. Impact of the opioid safety initiative on opioid-related prescribing in veterans. Pain 2017; 1585: 833–9. [DOI] [PubMed] [Google Scholar]
- 13. Centers for Disease Control and Prevention. Calculating Total Daily Dose of Opioids for Safer Dosage. Secondary Calculating Total Daily Dose of Opioids for Safer Dosage. 2016. https://www.cdc.gov/drugoverdose/pdf/calculating_total_daily_dose-a.pdf. Accessed on July 19, 2019.
- 14. Cedars-Sinai Medical Center. Audited Consolidated Financial Statements, Reports, Supplementary Information, and Schedule Required by Uniform Guidance: Cedars-Sinai Medical Center. Los Angeles, CA; 2017. [Google Scholar]
- 15. Centers for Disease Control and Prevention NCfIPaC. Analyzing Prescription Data and Morphine Milligram Equivalents (MME). Secondary Analyzing Prescription Data and Morphine Milligram Equivalents (MME). 2017. https://www.cdc.gov/drugoverdose/resources/data.html. Accessed September 29, 2017.
- 16. Schiff GD, Hickman T-TT, Volk LA, Bates DW, Wright A.. Computerised prescribing for safer medication ordering: still a work in progress. BMJ Qual Saf 2016; 255: 315.. [DOI] [PubMed] [Google Scholar]
- 17. Giavarina D. Understanding Bland Altman analysis. Biochem Med 2015; 252: 141–51. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 18. Bland JM, Altman D.. Statistical methods for assessing agreement between two methods of clinical measurement. Lancet 1986; 3278476: 307–10. [PubMed] [Google Scholar]
Associated Data
This section collects any data citations, data availability statements, or supplementary materials included in this article.