| Literature DB >> 32141068 |
Kathryn Rough1, Andrew M Dai1, Kun Zhang1, Yuan Xue1, Laura M Vardoulakis1, Claire Cui1, Atul J Butte2, Michael D Howell1, Alvin Rajkomar1,3.
Abstract
In a general inpatient population, we predicted patient-specific medication orders based on structured information in the electronic health record (EHR). Data on over three million medication orders from an academic medical center were used to train two machine-learning models: A deep learning sequence model and a logistic regression model. Both were compared with a baseline that ranked the most frequently ordered medications based on a patient's discharge hospital service and amount of time since admission. Models were trained to predict from 990 possible medications at the time of order entry. Fifty-five percent of medications ordered by physicians were ranked in the sequence model's top-10 predictions (logistic model: 49%) and 75% ranked in the top-25 (logistic model: 69%). Ninety-three percent of the sequence model's top-10 prediction sets contained at least one medication that physicians ordered within the next day. These findings demonstrate that medication orders can be predicted from information present in the EHR.Entities:
Mesh:
Year: 2020 PMID: 32141068 PMCID: PMC7325318 DOI: 10.1002/cpt.1826
Source DB: PubMed Journal: Clin Pharmacol Ther ISSN: 0009-9236 Impact factor: 6.875
Figure 1Schematic of study design and prediction task: Illustration of patient timeline, training data, model input, and model predictions for a hypothetical patient. Historical data from a patient’s electronic health record is aggregated into a single timeline. In this example, prior outpatient encounters are represented as ovals; inpatient encounters are represented as rectangles. One training example is generated for each inpatient medication order placed (marked by gray squares). Input to the model includes data from the patient's timeline up to the time of the order, but no future information. At the time of each medication order, the model outputs the probability that each of the 990 candidate medications will be ordered within the next 10 minutes. The two drugs ordered by a clinician at this time point (i.e., ground truth) appear in bold type.
Descriptive characteristics in training, validation, and test sets for inpatient medication order prediction task
| Patient‐level characteristics | Training set | Validation set | Test set |
|---|---|---|---|
| ( | ( | ( | |
| Sex, | |||
| Female | 35,957 (56.5) | 3,607 (55.5) | 3,680 (57.7) |
| Male | 27,638 (43.5) | 2,895 (44.5) | 2,702 (42.3) |
| Unknown | 6 (< 0.1) | 2 (< 0.1) | 1 (< 0.1) |
| Race, | |||
| White | 35,791 (56.3) | 3,598 (55.3) | 3,658 (57.3) |
| Black/African American | 4,913 (7.7) | 500 (7.7) | 485 (7.6) |
| Asian/Pacific Islander | 9,786 (15.4) | 1,024 (15.7) | 962 (15.1) |
| Other (including multiple races) | 10,456 (16.4) | 1,118 (17.2) | 1,055 (16.5) |
| Unknown | 2,655 (4.2) | 264 (4.1) | 223 (3.5) |
|
|
|
|
|
| Age, | |||
| 18–34 years | 19,326 (19.6) | 2,093 (20.6) | 2,033 (20.4) |
| 35–64 years | 49,029 (49.8) | 4,940 (49.9) | 4,960 (49.7) |
| 65–85 years | 25,618 (26.0) | 2,482 (25.1) | 2,561 (25.7) |
| >85 years | 4,506 (4.6) | 446 (4.5) | 424 (4.2) |
| Hospital discharge service, | |||
| General medicine | 21,803 (21.1) | 2,129 (21.5) | 2,168 (21.7) |
| Neurosurgery | 10,465 (10.6) | 1,068 (10.8) | 1,047 (10.5) |
| Obstetrics | 10,325 (10.5) | 1,071 (10.8) | 1,064 (10.7) |
| Orthopedics | 7,741 (7.9) | 762 (7.7) | 839 (8.4) |
| Transplant | 7,393 (7.5) | 753 (7.6) | 707 (7.1) |
| General surgery | 6,616 (6.7) | 628 (6.3) | 712 (7.1) |
| Cardiology | 5,770 (5.9) | 551 (5.6) | 606 (6.1) |
| Oncology | 5,260 (5.3) | 575 (5.8) | 515 (5.2) |
| Urology | 3,745 (3.8) | 384 (3.9) | 353 (3.5) |
| All other services | 19,361 (19.7) | 1,986 (20.0) | 1,967 (19.7) |
| Previous hospitalizations, | |||
| None | 63,284 (64.2) | 6,478 (65.4) | 6,346 (63.6) |
| One | 16,709 (17.0) | 1,702 (17.2) | 1,686 (16.9) |
| Two or more | 18,522 (18.8) | 1,727 (17.4) | 1,946 (19.5) |
|
|
|
|
|
| Number of medications per order event, median (25th percentile, 75th percentile) | 3 (2, 5) | 2 (2, 4) | 2 (2, 4) |
|
|
|
|
|
Other services: Cardiac surgery, colorectal surgery, critical care medicine, emergency medicine, gynecological oncology, gynecology, hepatobiliary medicine, medical speciality, neurology, oral/maxillofacial surgery, other surgery, otorhinolaryngology, pediatric (≥ 18 years of age), plastic surgery, pulmonary medicine, thoracic surgery, vascular surgery, and other/unknown.
Model performance for inpatient medication prediction task, with 95% confidence intervals (measured in the held‐out test set)
| LSTM sequence model: All variables | LSTM sequence model: No medication variables | Logistic regression model | Frequency comparator | |
|---|---|---|---|---|
| Top‐5 recall | 0.390 (0.389, 0.391) | 0.360 (0.359, 0.390) | 0.340 (0.339, 0.342) |
|
| Top‐10 recall | 0.552 (0.550, 0.553) | 0.520 (0.519, 0.552) | 0.489 (0.487, 0.490) |
|
| Top‐15 recall | 0.645 (0.644, 0.646) | 0.615 (0.614, 0.644) | 0.579 (0.577, 0.581) |
|
| Top‐25 recall | 0.750 (0.749, 0.751) | 0.723 (0.722, 0.745) | 0.686 (0.684, 0.687) |
|
| Micro‐weighted AU‐PRC | 0.299 (0.297, 0.300) | 0.258 (0.257, 0.299) | 0.193 (0.191, 0.195) | — |
| Micro‐weighted AU‐ROC | 0.977 (0.977, 0.977) | 0.974 (0.974, 0.977) | 0.956 (0.955, 0.956) | — |
Many medications can be ordered simultaneously in inpatient settings: 20% of order events have ≥ 5 medications actually ordered, 7% have ≥ 10 medications ordered, 4% have ≥ 15 medications ordered, 1% have ≥ 25 medications ordered. This places a bound on the highest attainable top‐k recall metrics (i.e., a perfect model would achieve only 80% top‐5 recall). For alternative calculation of recall metrics, please see Table .
AU‐PRC, area under the precision‐recall curve; AU‐ROC, area under the receiver operating curve; LSTM, long short‐term memory.
95% Confidence intervals were calculated from 1,000 bootstrapped samples.
LSTM sequence model trained with no information on previous medications.
The frequency comparator ranked the top‐k most frequently ordered medications based on the time between hospital admission and the placement of the order (< 1 day, 1–3 days, 3–5 days, and > 5 days) and the patient’s discharge hospital service.
Top‐k recall is the proportion of medications actually ordered by physicians that appear in the model’s top‐k most probable medication predictions.
Figure 2Illustrative example of LSTM sequence model‐generated medication predictions for a single patient. Predictions produced by the LSTM sequence model at three time points during a patient’s hospitalization are shown. Medications that were actually placed by clinicians (i.e., ground truth) are underlined. We display a small subset of vital signs and laboratory results collected during the hospitalization, represented as empty circles. Black circles denote antibiotic medications, gray squares denote antihypertensive medications, and white diamonds denote immunosuppressant medications. Near admission, the model predicts multiple antibiotics and pain relievers (order A). Soon after, for order B, the model assigns high probability for multiple immunosuppressive medications typically administered to transplant patients. Several days into the hospitalization, the patient’s blood pressure rises; the LSTM sequence model predicts a variety of antihypertensives, including an intravenous formulation of hydralazine (order C). BP, blood pressure (measured in millimeters of mercury); HR, heart rate (measured in beats per minute); LSTM, long short‐term memory; Temp, temperature (measured in degrees Fahrenheit); WBC, white blood cell (measured in thousands of cells per microliter). *“Clonidine, oral” was ranked 36 by the LSTM sequence model at this time point. Note: Corresponding predictions for the logistic model can be found in Figure .
Figure 3Top‐10 recall for the inpatient medication prediction task by hospital discharge service (measured in the held‐out test set). Top‐10 recall is the proportion of medications actually ordered by physicians that appear in the model’s top‐10 most probable medication predictions. LSTM, long short‐term memory.
Figure 4Physician ordering of top LSTM sequence model‐predicted medications within a specified postprediction time window (measured in the held‐out test set). (a) The percentage of top‐1, top‐5, and top‐10 LSTM sequence model‐predicted medications ordered by physicians within the specified postprediction time window. (b) The percentage of top‐1, top‐5, and top‐10 LSTM sequence model‐predicted sets where at least one medication is ordered by physicians within the specified postprediction time window. LSTM, long short‐term memory.