Abstract
Electronic Health Records (EHR) data is routinely generated patient data that can provide useful information for analytical tasks such as disease detection and clinical event prediction. However, temporal EHR data such as physiological vital signs and lab test results are particularly challenging. Temporal EHR features typically have different sampling frequencies; such examples include heart rate (measured almost continuously) and blood test results (a few times during a patient’s entire stay). Different patients also have different length of stays. Existing approaches for temporal EHR sequence extraction either ignore the temporal pattern within features, or use a predefined window to select a section of the sequences without taking into account all the information. We propose a novel approach to tackle the issue of irregularly sampled, unequal length EHR time series using dynamic time warping and tensor decomposition. We use DTW to learn the pairwise distances for each temporal feature among the patient cohort and stack the distance matrices into a tensor. We then decompose the tensor to learn the latent structure, which is consequently used for patient representation. Finally, we use the patient representation for in-hospital mortality prediction. We illustrate our method on two cohorts from the MIMIC-III database: the sepsis and the acute kidney failure cohorts. We show that our method produces outstanding classification performance in terms of AUROC, AUPRC and accuracy compared with the baseline methods: LSTM and DTW-KNN. In the end we provide a detailed analysis on the feature importance for the interpretability of our method.
Similar content being viewed by others
Explore related subjects
Discover the latest articles, news and stories from top researchers in related subjects.References
Acar E, Levin-Schwartz Y, Calhoun VD, Adali T (2017) Tensor-based fusion of EEG and FMRI to understand neurological changes in schizophrenia. In: Proceedings—IEEE international symposium on circuits and systems, pp 1–4. https://doi.org/10.1109/ISCAS.2017.8050303
Afshar A, Perros I, Papalexakis EE, Searles E, Ho J, Sun J (2018) COPA: constrained PARAFAC2 for sparse and large datasets. In: The 27th ACM international conference on information and knowledge management (CIKM ’18). https://doi.org/10.1145/3269206.3271775
Alaa AM, van der Schaar M (2018) Forecasting individualized disease trajectories using interpretable deep learning. arXiv:1810.10489
Allardet-Servent J, Forel JM, Roch A, Guervilly C, Chiche L, Castanier M, Embriaco N, Gainnier M, Papazian L (2009) FiO2 and acute respiratory distress syndrome definition during lung protective ventilation. Crit Care Med 37(1):202–207. https://doi.org/10.1097/CCM.0b013e31819261db
Bagnall A, Bostrom A, Large J, Lines J (2016) The great time series classification bake off: an experimental evaluation of recently proposed algorithms. Extended version arXiv:1602.01711
Che C, Xiao C, Liang J, Jin B, Zho J, Wang F (2017) An RNN architecture with dynamic temporal matching for personalized predictions of Parkinson’s disease. In: Proceedings of the 2017 SIAM international conference on data mining, pp 198–206. https://doi.org/10.1137/1.9781611974973.23
Chollet F (2015) Keras. https://keras.io
Dau HA, Silva DF, Petitjean F, Forestier G, Bagnall A, Keogh E (2017) Judicious setting of Dynamic Time Warping’s window width allows more accurate classification of time series. In: Proceedings—2017 IEEE international conference on big data, big data 2017. https://doi.org/10.1109/BigData.2017.8258009
Fanaee-T H, Oliveira M, Gama J, Malinowski S, Morla R (2013) Event and anomaly detection using tucker3 decomposition. In: Proceedings of 20th European conference on artificial intelligence (ECAI’2013)-ubiquitous data mining workshop, vol 1, pp 8–12. arXiv:1406.3266v1
Filho RR, Rocha LL, Correa TD, Pessoa CMS, Colombo G, Assuncao MSC (2016) Blood lactatte levels cutoff and mortality prediction in sepsis—time for a reappraisal? A retrospective cohort study. Shock 46(5):480–485. https://doi.org/10.1097/SHK.0000000000000667
Geler Z, Kurbalija V, Ivanovic M, Radovanovic M, Dai W (2019) Dynamic time warping: Itakura vs Sakoe–Chiba. In: IEEE international symposium on innovations in intelligent systems and applications, INISTA 2019—Proceedings. https://doi.org/10.1109/INISTA.2019.8778300
Ghassemi M, Naumann T, Schulam P, Beam AL, Ranganath R (2018) Opportunities in machine learning for healthcare. arXiv:1806.00388
Giorgino T (2009) Computing and visualizing dynamic time warping alignments in R: the dtw package. J Stat Softw 31(7):1–24. https://doi.org/10.18637/jss.v031.i07
Guo C, Lu M, Chen J (2020a) An evaluation of time series summary statistics as features for clinical prediction tasks. BMC Med Inform Decis Mak 20(1):1–20. https://doi.org/10.1186/s12911-020-1063-x
Guo D, Duan G, Yu Y, Li Y, Wu FX (2020b) A disease inference method based on symptom extraction and bidirectional Long Short Term Memory networks. Methods 173(April 2019):75–82. https://doi.org/10.1016/j.ymeth.2019.07.009
Harutyunyan H, Khachatrian H, Kale DC, Steeg GV, Galstyan A (2018) Multitask learning and benchmarking with clinical time series data. arXiv:1703.07771
Henderson J, Ho JC, Kho AN, Denny JC, Malin BA, Sun J, Ghosh J (2017) Granite: diversified. Sparse tensor factorization for electronic health record-based phenotyping. In: IEEE international conference on healthcare informatics (ICHI). https://doi.org/10.1109/ICHI.2017.61
Henderson J, Malin BA, Ho JC (2018) PIVETed-granite: computational phenotypes through constrained tensor factorization. arXiv:1808.02602v1
Ho J, Ghosh J, Steinhubl SR, Stewart WF, Denny JC, Malin BA, Sun J (2014a) Limestone: high-throughput candidate phenotype generation via tensor factorization. J Biomed Inform 52:199–211. https://doi.org/10.1016/j.jbi.2014.07.001
Ho J, Ghosh J, Sun J (2014b) Marble: high-throughput phenotyping from electronic health records via sparse nonnegative tensor factorization. In: Proceedings of the 20th ACM SIGKDD international conference on Knowledge discovery and data mining, pp 115–124. https://doi.org/10.1145/2623330.2623658
Itakura F (1975) Minimum prediction residual principle applied to speech recognition. IEEE Trans Acoust Speech Signal Process 23(1):67–72. https://doi.org/10.1109/TASSP.1975.1162641
Johnson AE, Pollard TJ, Shen L, Lehman LWH, Feng M, Ghassemi M, Moody B, Szolovits P, Celi AL, Mark RG (2016) MIMIC-III, a freely accessible critical care database. Sci Data 3:160035. https://doi.org/10.1038/sdata.2016.35. https://www.nature.com/articles/sdata201635
Johnson AEW, Pollard TJ, Mark RG (2017) Reproducibility in critical care: a mortality prediction case study. In: 2nd machine learning for healthcare conference, PMLR, vol 68. http://proceedings.mlr.press/v68/johnson17a.html
Kaji DA, Zech JR, Kim JS, Cho SK, Dangayach NS, Costa AB, Oermann EK (2019) An attention based deep learning model of clinical events in the intensive care unit. PLoS ONE 14(2):1–17. https://doi.org/10.1371/journal.pone.0211057
Keogh EJ, Pazzani MJ (1999) Scaling up dynamic time warping to massive datasets. Princ Data Min Knowl Discov 1704(Derriere):1–11. https://doi.org/10.1007/978-3-540-48247-5_1
Kiers HAL (2000) Towards a standardized notation and terminology in multiway analysis. J Chemom 14:105–122
Kolda TG, Bader BW (2009) Tensor decompositions and applications. SIAM Rev 51(3):455–500. https://doi.org/10.1137/07070111X
Kruse CS, Goswamy R, Raval Y, Marawi S (2016) Challenges and opportunities of big data in health care: a systematic review. JMIR Med Inform 4(4):e38. https://doi.org/10.2196/medinform.5359
Le Gall JR, Lemeshow S, Saulnier F (1993) Simplified Acute Physiology Score ( SAPS II ) Based on a European/North American Multicenter Study. JAMA 270(24):2957–2963
Legrand M, Payen D (2011) Understanding urine output in critically ill patients. Ann Intensive Care 1(1):13. https://doi.org/10.1186/2110-5820-1-13. http://www.annalsofintensivecare.com/content/1/1/13
Lei L, Zhou Y, Zhai J, Zhang L, Fang Z, He P, Gao J (2018) An effective patient representation learning for time-series prediction tasks based on EHRs. In: Proceedings—2018 IEEE international conference on bioinformatics and biomedicine, BIBM 2018. https://doi.org/10.1109/BIBM.2018.8621542
Li Y, Chaiteerakij R, Kwon JH, Jang JW, Lee HL, Cha S, Ding XW, Thongprayoon C, Ha FS, Nie CY, Zhang Q, Yang Z, Giama NH, Roberts LR, Han T (2018) A model predicting short-term mortality in patients with advanced liver cirrhosis and concomitant infection. Medicine 97(41):e12758
Lin YW, Zhou Y, Faghri F, Shaw M, Campbell R (2019) Analysis and prediction of unplanned intensive care unit readmission using recurrent neural networks with long short-term memory. PLoS ONE 14(7):e0218942. https://doi.org/10.1371/journal.pone.0218942
Lipton ZC (2016) The mythos of model interpretability. arXiv:1606.03490
Lipton ZC, Kale DC, Elkan C, Wetzel R (2016) Learning to diagnose with LSTM recurrent neural networks. In: 4th international conference on learning representations, ICLR 2016—conference track proceedings, pp 1–18. arXiv:1511.03677
Luo Y, Xin Y, Joshi R, Celi L, Szolovits P (2016) Predicting ICU mortality risk by grouping temporal trends from a multivariate panel of physiologic measurements. In: 30th AAAI conference on artificial intelligence, AAAI 2016, pp 42–50
Moor M, Horn M, Rieck B, Roqueiro D, Borgwardt K (2019) Early recognition of sepsis with Gaussian process temporal convolutional networks and dynamic time warping. arXiv:1902.01659
Muller M (2007) Dynamic time warping. In: Information retrieval for music and motion, Springer, Berlin, Heidelberg, chap 4, pp 69–84
Murali AR, Devarbhavi H, Venkatachala PR, Singh R, Sheth KA (2014) Factors that predict 1-month mortality in patients with pregnancy-specific liver disease. Clin Gastroenterol Hepatol 12(1):109–113. https://doi.org/10.1016/j.cgh.2013.06.018
Niennattrakul V, Ratanamahatana CA (2009) Learning DTW global constraint for time series classification. arXiv:0903.0041
Park BS, Yoon JS, Moon JS, Won KC, Lee HW (2013) Predicting mortality of critically ill patients by blood glucose levels. Diabetes Metab J 37:385–390
Perros I, Papalexakis EE, Wang F, Vuduc R, Searles E, Thompson M, Sun J (2017) SPARTan: scalable PARAFAC2 for large and sparse data. In: KDD. https://doi.org/10.1145/3097983.3098014
Purushotham S, Meng C, Che Z, Liu Y (2018) Benchmarking deep learning models on large healthcare datasets. J Biomed Inform 83:112–134. https://doi.org/10.1016/j.jbi.2018.04.007
Rabanser S, Shchur O, Günnemann S (2017) Introduction to tensor decompositions and their applications in machine learning, pp 1–13. arXiv:1711.10781
Ratanamahatana CA, Keogh E (2004) Making time-series classification more accurate using learned constraints. In: SIAM proceedings series, pp 11–22. https://doi.org/10.1137/1.9781611972740.2
Reimers N, Gurevych I (2017) Optimal hyperparameters for deep LSTM-networks for sequence labeling tasks. arXiv:1707.06799
Ribas Ripoll VJ, Vellido A, Romero E, Ruiz-Rodríguez JC (2014) Sepsis mortality prediction with the quotient basis kernel. Artif Intell Med 61(1):45–52. https://doi.org/10.1016/j.artmed.2014.03.004
Ruffini M, Gavaldà R, Limón E (2017) Clustering patients with tensor decomposition 68. https://doi.org/10.1002/dei. arXiv:1708.08994
Sakoe H, Chiba S (1978) Dynamic programming algorithm optimization for spoken word recognition. IEEE Trans Acoust Speech Signal Process ASSP 26(1):43–49
Salvador S, Chan P (2007) FastDTW: toward accurate dynamic time warping in linear time and space. Intell Data Anal 11(5):561–580. https://doi.org/10.3233/ida-2007-11508
Sanderson M, Chikhani M, Blyth E, Wood S, Moppett IK, Mckeever T, Simmonds MJR (2018) Predicting 30-day mortality in patients with sepsis: an exploratory analysis of process of care and patient characteristics. J Intensive Care Soc 19(4):299–304. https://doi.org/10.1177/1751143718758975
Scherpf M, Gräßer F, Malberg H, Zaunseder S (2019) Predicting sepsis with a recurrent neural network using the MIMIC III database. Comput Biol Med 113(June):103395. https://doi.org/10.1016/j.compbiomed.2019.103395
Shokoohi-Yekta M, Hu B, Jin H, Wang J, Keogh E (2017) Generalizing DTW to the multi-dimensional case requires an adaptive approach. Data Min Knowl Disc 31(1):1–31. https://doi.org/10.1007/s10618-016-0455-0
Sidiropoulos ND, De Lathauwer L, Fu X, Huang K, Papalexakis EE, Faloutsos C (2017) Tensor decomposition for signal processing and machine learning. IEEE Trans Signal Process 65(13):3551–3582. https://doi.org/10.1109/TSP.2017.2690524. arXiv:1607.01668
Song H, Rajan D, Thiagarajan JJ, Spanias A (2018) Attend and diagnose: clinical time series analysis using attention models. In: 32nd AAAI conference on artificial intelligence, AAAI 2018, pp 4091–4098. arXiv:1711.03905
Suresh H, Gong JJ, Guttag J (2018) Learning tasks for multitask learning: heterogenous patient populations in the ICU. In: KDD. https://doi.org/10.1145/3219819.3219930. arXiv:1806.02878
Tan CW, Petitjean F, Webb GI (2019) FastEE: fast ensembles of elastic distances for time series classification. Data Min Knowl Discovy. https://doi.org/10.1007/s10618-019-00663-x
Ting H, Chen M, Hsieh Y, Chan C (2010) Good mortality prediction by Glasgow Coma scale for neurosurgical patients. J Chin Med Assoc 73(3):139–143. https://doi.org/10.1016/S1726-4901(10)70028-9
Trzeciak S, Dellinger RP, Chansky ME, Arnold RC, Schorr C, Milcarek B, Hollenberg SM, Parrillo JE (2007) Serum lactate as a predictor of mortality in patients with infection. Intensive Care Med 33:970–977. https://doi.org/10.1007/s00134-007-0563-9
Vervliet N, Debals O, Sorber L, Van Barel M, De Lathauwer L (2016) Tensorlab 3.0
Xiao C, Choi E, Sun J (2018) Opportunities and challenges in developing deep learning models using electronic health records data: a systematic review. J Am Med Inform Assoc 25(10):1419–1428. https://doi.org/10.1093/jamia/ocy068
Yu K, Zhang M, Cui T, Hauskrecht M (2020) Monitoring ICU mortality risk with a long short-term memory recurrent neural network. Pac Symp Biocomput 25:103–114. https://doi.org/10.1142/9789811215636_0010
Zhang Z, Xu X, Ni H, Deng H (2014) Urine output on ICU entry is associated with hospital mortality in unselected critically ill patients. J Nephrol 27:65–71. https://doi.org/10.1007/s40620-013-0024-1
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors declare that they have no conflict of interest.
Additional information
Responsible editor: Panagiotis Papapetrou.
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
About this article
Cite this article
Zhang, C., Fanaee-T, H. & Thoresen, M. Feature extraction from unequal length heterogeneous EHR time series via dynamic time warping and tensor decomposition. Data Min Knowl Disc 35, 1760–1784 (2021). https://doi.org/10.1007/s10618-020-00724-6
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10618-020-00724-6