Development and Internal Validation of Machine Learning Algorithms for Predicting Hyponatremia After TJA.
Academic Article
Overview
abstract
BACKGROUND: The development of hyponatremia after total joint arthroplasty (TJA) may lead to several adverse events and is associated with prolonged inpatient length of stay as well as increased hospital costs. The purpose of this study was to develop and internally validate machine learning algorithms for predicting hyponatremia after TJA. METHODS: A consecutive cohort of 30,703 TJA patients from an institutional registry at a large, tertiary academic hospital were included. A total of 19 potential predictor variables were collected. Hyponatremia was defined as a serum sodium concentration of <135 mEq/L. Five machine learning algorithms were developed using a training set and internally validated using an independent testing set. Algorithm performance was evaluated through discrimination, calibration, decision-curve analysis, and Brier score. RESULTS: The charts of 30,703 patients undergoing TJA were reviewed. Of those patients, 5,480 (17.8%) developed hyponatremia postoperatively. A combination of 6 variables were demonstrated to optimize algorithm prediction: preoperative serum sodium concentration, age, intraoperative blood loss, procedure time, body mass index (BMI), and American Society of Anesthesiologists (ASA) score. Threshold values that were associated with greater hyponatremia risk were a preoperative serum sodium concentration of ≤138 mEq/L, an age of ≥73 years, an ASA score of >2, intraoperative blood loss of >407 mL, a BMI of ≤26 kg/m2, and a procedure time of >111 minutes. The stochastic gradient boosting (SGB) algorithm demonstrated the best performance (c-statistic: 0.75, calibration intercept: -0.02, calibration slope: 1.02, and Brier score: 0.12). This algorithm was turned into a tool that can provide real-time predictions (https://orthoapps.shinyapps.io/Hyponatremia_TJA/). CONCLUSIONS: The SGB algorithm demonstrated the best performance for predicting hyponatremia after TJA. The most important factors for predicting hyponatremia were preoperative serum sodium concentration, age, intraoperative blood loss, procedure time, BMI, and ASA score. A real-time hyponatremia risk calculator was developed, but it is imperative to perform external validation of this model prior to using this calculator in clinical practice. LEVEL OF EVIDENCE: Prognostic Level IV. See Instructions for Authors for a complete description of levels of evidence.