Machine learning-assisted screening of clinical features for predicting difficult-to-treat rheumatoid arthritis

Sci Rep. 2025 Oct 6;15(1):34747. doi: 10.1038/s41598-025-18298-y.

Abstract

To identify clinical features that predict the risk of meeting difficult-to-treat (D2T) rheumatoid arthritis (RA) definition in advance. This retrospective analysis included RA patients from the ATTRA registry who initiated biologic (b-) or targeted synthetic (ts-) disease-modifying anti-rheumatic drugs (DMARDs) between 2002 and 2023. Patients with D2T RA met the EULAR criteria, while controls achieved sustained remission, defined as a Simple Disease Activity Index (SDAI) < 3.3 and a Swollen Joint Count (SJC) ≤ 1, maintained across two consecutive visits 12 weeks apart. Patients were assessed at baseline and at one and two years before fulfilling the D2T RA definition. Predictive models were developed using machine learning techniques (lasso and ridge logistic regression, support vector machines, random forests, and XGBoost). Shapley additive explanation (SHAP) values were used to assess the contribution of individual variables to model predictions. Among 8,543 RA patients, 641 met the criteria for D2T RA, while 1,825 achieved remission. The machine learning models demonstrated an accuracy range of 0.606-0.747, with an area under the receiver operating characteristic curve (AUC) of 0.656-0.832 for predicting D2T RA. SHAP analysis highlighted key predictive variables, including disease activity measures (DAS28-ESR, CDAI, CRP), patient-reported outcomes (HAQ), and the duration of b/tsDMARD treatment. We identified clinical features predictive of D2T RA at baseline and up to one year before meeting the formal criteria. These findings provide valuable insights into early indicators of D2T RA progression and support the importance of earlier recognition and timely therapeutic intervention to improve long-term patient outcomes.

Keywords: Difficult-to-treat rheumatoid arthritis; Explainable artificial intelligence; Machine learning; Real-world data.

MeSH terms

  • Adult
  • Aged
  • Antirheumatic Agents* / therapeutic use
  • Arthritis, Rheumatoid* / diagnosis
  • Arthritis, Rheumatoid* / drug therapy
  • Female
  • Humans
  • Machine Learning*
  • Male
  • Middle Aged
  • Registries
  • Retrospective Studies
  • Severity of Illness Index

Substances

  • Antirheumatic Agents