A Machine Learning Approach to Developing an Accurate Prediction of Maximal Heart Rate During Exercise Testing in Apparently Healthy Adults

J Cardiopulm Rehabil Prev. 2023 Sep 1;43(5):377-383. doi: 10.1097/HCR.0000000000000786. Epub 2023 Mar 8.

Abstract

Purpose: Maximal heart rate (HR max ) continues to be an important measure of adequate effort during an exercise test. The aim of this study was to improve the accuracy of HR max prediction using a machine learning (ML) approach.

Methods: We used a sample from the Fitness Registry of the Importance of Exercise National Database, which included 17 325 apparently healthy individuals (81% males) who performed a maximal cardiopulmonary exercise test. Two standard formulas for HR max prediction were tested: Formula1 = 220 - age (yr), root-mean-squared error (RMSE) 21.9, relative root-mean-squared error (RRMSE) 1.1; and Formula2 = 209.3 - 0.72 × age (yr), RMSE 22.7 and RRMSE 1.1. For ML model prediction, we used age, weight, height, resting HR, and systolic and diastolic blood pressure. The following ML algorithms to predict HR max were applied: lasso regression (LR), neural networks (NN), support vector machine (SVM) and random forests (RF). An evaluation was performed using cross-validation and by computing the RMSE and RRMSE, Pearson correlation, and Bland-Altman plots. The best predictive model was explained with Shapley Additive Explanations (SHAP).

Results: The HR max for the cohort was 162 ± 20 bpm. All ML models improved HR max prediction and reduced RMSE and RRMSE compared with Formula1 (LR: 20.2%, NN: 20.4%, SVM: 22.2%, and RF: 24.7%). The predictions of all algorithms significantly correlated with HR max ( r = 0.49, 0.51, 0.54, 0.57, respectively; P < .001). Bland-Altman analysis demonstrated lower bias and 95% CI for all ML models in comparison with standard equations. The SHAP explanation showed a high impact of all selected variables.

Conclusions: Machine learning, particularly the RF model, improved prediction of HR max using readily available measures. This approach should be considered for clinical application to refine HR max prediction.

Publication types

  • Research Support, Non-U.S. Gov't

MeSH terms

  • Adult
  • Exercise Test*
  • Exercise*
  • Female
  • Heart Rate / physiology
  • Humans
  • Machine Learning
  • Male
  • Random Forest