Abstract
Background and Objectives: Multidrug Resistance (MDR) is a critical globalhealth issue, causing increased hospital stays, healthcare costs, andmortality. This study proposes an interpretable Machine Learning (ML) frameworkfor MDR prediction, aiming for both accurate inference and enhancedexplainability. Methods: Patients are modeled as Multivariate Time Series (MTS), capturingclinical progression and patient-to-patient interactions. Similarity amongpatients is quantified using MTS-based methods: descriptive statistics, DynamicTime Warping, and Time Cluster Kernel. These similarity measures serve asinputs for MDR classification via Logistic Regression, Random Forest, andSupport Vector Machines, with dimensionality reduction and kerneltransformations improving model performance. For explainability, patientsimilarity networks are constructed from these metrics. Spectral clustering andt-SNE are applied to identify MDR-related subgroups and visualize high-riskclusters, enabling insight into clinically relevant patterns. Results: The framework was validated on ICU Electronic Health Records fromthe University Hospital of Fuenlabrada, achieving an AUC of 81%. It outperformsbaseline ML and deep learning models by leveraging graph-based patientsimilarity. The approach identifies key risk factors -- prolonged antibioticuse, invasive procedures, co-infections, and extended ICU stays -- and revealsclinically meaningful clusters. Code and results are available at\https://github.com/oscarescuderoarnanz/DM4MTS. Conclusions: Patient similarity representations combined with graph-basedanalysis provide accurate MDR prediction and interpretable insights. Thismethod supports early detection, risk factor identification, and patientstratification, highlighting the potential of explainable ML in critical care.