Machine learning prediction model for early postoperative hypoalbuminemia after pulmonary surgery: a retrospective case-matched comparative study
Original Article

Machine learning prediction model for early postoperative hypoalbuminemia after pulmonary surgery: a retrospective case-matched comparative study

Wei Mao1#, Huer Gao2#, Yeyan Hu3 ORCID logo, Xinghua Cheng1

1Department of Shanghai Lung Cancer Center, Shanghai Chest Hospital, School of Medicine, Shanghai Jiao Tong University, Shanghai, China; 2School of Information Science and Technology, ShanghaiTech University, Shanghai, China; 3Department of Pharmacy, Shanghai Chest Hospital, School of Medicine, Shanghai Jiao Tong University, Shanghai, China

Contributions: (I) Conception and design: W Mao, Y Hu; (II) Administrative support: W Mao, Y Hu, X Cheng; (III) Provision of study materials or patients: W Mao, Y Hu, X Cheng; (IV) Collection and assembly of data: W Mao, H Gao, Y Hu; (V) Data analysis and interpretation: W Mao, H Gao, Y Hu; (VI) Manuscript writing: All authors; (VII) Final approval of manuscript: All authors.

#These authors contributed equally to this work.

Correspondence to: Yeyan Hu, MPH. Department of Pharmacy, Shanghai Chest Hospital, School of Medicine, Shanghai Jiao Tong University, No. 241, Huaihai West Road, Xuhui District, Shanghai 200030, China. Email: hyygq@aliyun.com; Xinghua Cheng, PhD. Department of Shanghai Lung Cancer Center, Shanghai Chest Hospital, School of Medicine, Shanghai Jiao Tong University, No. 241, Huaihai West Road, Xuhui District, Shanghai 200030, China. Email: chengxinghua_001@163.com.

Background: Perioperative hypoalbuminemia is associated with postoperative infection, anastomotic fistula, and a poor prognosis. Compared with the preoperative period, hypoalbuminemia is more prevalent following pulmonary surgery, particularly in the early postoperative phase, which is associated with various postoperative complications. Traditional risk assessment relies on clinical experience and basic laboratory indicators. Currently, no research has been conducted on the application of machine learning (ML) in the prediction of early postoperative hypoalbuminemia (EPH). This study aimed to develop an ML-based predictive model for EPH following pulmonary surgery, offering a novel tool for risk assessment and clinical decision-making in the perioperative management of thoracic surgery.

Methods: The data of patients diagnosed with primary lung cancer who underwent elective pulmonary surgery between January 2022 and December 2024 were retrospectively collected. Based on 1:1 case-control matching, the sample comprised 1,048 cases and 1,048 controls. The outcome variable was binary (the presence or absence of EPH after pulmonary surgery). A logistic regression (LR) model was built with 37 variables; the data were split 8:2 and validated by five-fold stratified cross-validation. Model performance was assessed based on the area under the curve (AUC), accuracy, precision, recall, F1, and Brier score, with SHapley Additive exPlanations (SHAP) used for interpretation.

Results: The model performance metrics were as follows: AUC of the receiver operating characteristic (ROC) curve: 0.8543, precision: 0.7947, recall: 0.7309, F1-score: 0.7606, accuracy: 0.771, and Brier score: 0.1551.

Conclusions: The LR-based ML algorithm demonstrated excellent performance and effectively identified patients at high risk of EPH after pulmonary surgery [serum albumin (ALB) <35 g/L within 5 days of pulmonary surgery].

Keywords: Machine learning prediction (ML prediction); early postoperative hypoalbuminemia (EPH); pulmonary surgery; lung cancer


Submitted Dec 13, 2025. Accepted for publication Jan 15, 2026. Published online Jan 27, 2026.

doi: 10.21037/jtd-2025-1-2620


Highlight box

Key findings

• This was the first study to develop a machine learning (ML)-based predictive model for early postoperative hypoalbuminemia (EPH) following pulmonary surgery, offering a novel tool for risk assessment and clinical decision-making.

What is known, and what is new?

• Perioperative hypoalbuminemia is closely associated with postoperative infection, anastomotic fistula and a poor prognosis. Traditional risk assessment relies on clinical experience and laboratory indicators. Currently, no research has been conducted on the application of ML in the prediction of EPH.

• Compared with the preoperative period, hypoalbuminemia is more prevalent following pulmonary surgery, particularly in the early postoperative phase, which is associated with various postoperative complications. Based on this finding, we integrated multi-dimensional data and built the first ML classifier to predict EPH. The model achieved an area under the curve of 0.85, which falls within the 0.7 to 0.9 range, indicating that the classifier has certain classification ability and shows good recognition performance. For a binary outcome, this degree of separation indicates that the algorithm can reliably distinguish between patients at high and low risk of developing EPH.

What is the implication, and what should change now?

• Clinical workflow: ML models should be integrated into perioperative management to tailor interventions, and operation methods should be selected cautiously for high-risk patients.

• Resource allocation: dietary supplements and medications should be appropriately used to ensure precise and timely treatment, and minimize ineffective or excessive medical care.

• Future research: multicenter studies should be conducted to enhance model generalization and robustness.


Introduction

Hypoalbuminemia is a common complication after pulmonary surgery, caused by negative nitrogen balance that can be influenced by a variety of factors. Previous studies have found that preoperative hypoalbuminemia is a risk factor for postoperative complications such as bronchopleural fistula, chylothorax, anastomotic leakage, infection, pulmonary edema, and pleural effusion (1-4). In addition, research has shown that hypoalbuminemia is significantly associated with a range of perioperative complications, including hypertensive crisis, thrombo-embolic events, and cardiac conduction abnormalities (5-7), and can serve as a predictor of adverse outcomes such as a prolonged hospital stay, a poor prognosis, and increased all-cause mortality (8-11).

The incidence of perioperative hypoalbuminemia varies significantly across different operations. Related studies have reported that the incidence of postoperative hypoalbuminemia in thoracic surgery is high (12,13). At our center (Shanghai Lung Cancer Center of Shanghai Chest Hospital) over the past 3 years, the incidence of perioperative hypoalbuminemia following thoracic surgery was approximately 15%. Among patients undergoing elective pulmonary resection, preoperative hypoalbuminemia occurred in only 5.3% of cases, whereas postoperative hypoalbuminemia occurred in 91.3% of cases. About half of these patients were aged 18–69 years, and more than 95% of cases of hypoalbuminemia developed within 5 days of surgery and were closely associated with postoperative complications (Figure S1 and Table S1).

Machine learning (ML) models automatically identify complex patterns in data through algorithms and are now widely used in medicine (14). Therefore, this study aimed to develop and validate a reliable clinical prediction model for early postoperative hypoalbuminemia (EPH) in patients whose preoperative albumin (ALB) levels were normal. enabling thoracic surgeons to promptly identify high-risk patients after pulmonary surgery and to deliver personalized medical interventions. We present this article in accordance with the TRIPOD reporting checklist (available at https://jtd.amegroups.com/article/view/10.21037/jtd-2025-1-2620/rc) (15).


Methods

The study was conducted in accordance with the Declaration of Helsinki and its subsequent amendments. The study was approved by the Ethics Committee of Shanghai Chest Hospital (IRB No. IS24081) and individual consent was waived for this retrospective study.

Subjects

All the data were retrospectively collected from the Hospital Information System (HIS) of Department of Shanghai Lung Cancer Center, Shanghai Chest Hospital (a tertiary Grade-A hospital) from January 2022 to December 2024. Patients were included in the study if they met the following inclusion criteria: (I) were aged 18 to 69 years at the initial diagnosis of the lung shadow and underwent elective pulmonary surgery; (II) completed 90-day postoperative follow-up at our center; and (III) had complete medical records available. Patients were excluded from the study if they met any of the following exclusion criteria: (I) had only mediastinal or pleural lesions based on pathology reports; (II) had a preoperative serum ALB level <35 g/L; and/or (III) had a postoperative ALB level <35 g/L detected within 5 days of the pulmonary surgery. See the study flow chart in Figure 1.

Figure 1 Study flow chart. Group A, early postoperative hypoalbuminemia; Group NA, perioperative non-hypoalbuminemia. ALB, serum albumin; LR, logistic regression.

Outcome

Hypoalbuminemia was diagnosed and graded according to the National Cancer Institute Common Terminology Criteria for Adverse Events (NCI-CTCAE) version 5.0 (16). Hypoalbuminemia was defined as a disorder characterized by laboratory test results indicating a low concentration of ALB in the blood, and was classified into five grades: Grade 1: mild adverse event (ALB < lower limit of normal and ≥30 g/L); Grade 2: moderate adverse event (ALB ≥20 to <30 g/L); Grade 3: severe or medically significant but not immediately life-threatening adverse event (ALB <20 g/L); Grade 4: life-threatening consequences; and Grade 5: death related to the adverse event.

At our center, the bromocresol green method was used to detect serum ALB, and the normal reference serum ALB level was 35–52 g/L (all the postoperative serum ALB measurements were performed by laboratory staff who were blinded to the patient characteristics and prediction-model variables; the treating surgeons and ward physicians were aware of all clinical data and made care decisions accordingly). The primary endpoint was a binary variable: the presence or absence of EPH. EPH was defined as a serum ALB level <35 g/L within 5 days of pulmonary surgery. Use the first postoperative serum ALB result obtained within 5 days after surgery if its value was below 35 g/L.

Sample size

The rule of at least 10 events per predictor parameter (EPPs) is regularly used to calculate sample sizes for new model development (17). In this study, the sample size was calculated using the 20 EPP rule to enhance model robustness. Given 37 actual predictor variables (selected from 46 candidate parameters), a minimum of 920 positive events were required for model development.

We screened patients who developed postoperative hypoalbuminemia in a 90-day postoperative follow-up period at our center over the past 3 years (annual case load: 2022, n=352; 2023, n=342; 2024, n=412). A total of 1,048 patients with EPH who met the inclusion criteria comprised the case group. The observed number of positive events exceeded the estimated requirement, confirming the feasibility of the study design. To minimize surgical-technique bias, we performed 1:1 case-control matching by pairing each EPH patient with a control patient who had undergone pulmonary surgery by the same surgeon but who did not develop perioperative hypoalbuminemia.

Model development

Data preprocessing and variable selection

Perioperative data were systematically collected, processed, and classified in accordance with established literature and clinical expertise. According to the NCI-CTCAE criteria, every case of suspected hypoproteinemia was thoroughly re-reviewed at the time of data collection, with particular scrutiny of the reported serum ALB values. Rigorous quality control measures were implemented before the analytical procedures, including a double-check of the data, and the exclusion of missing data or incomplete records.

Based on published literature and clinical expert consensus, 37 perioperative variables were chosen as model predictors: pre-operative data (patient demographics, medical history, and laboratory indices), intra-operative parameters, and information recorded within the first 24 post-operative hours (Table 1). To facilitate clinical use and preserve the statistical information, we processed the continuous independent variables, including age. The multi-categorical independent variables were divided into ordered categorical variables, which included the body mass index (BMI), Nutritional Risk Screening 2002 (NRS-2002) score, D-dimer, and blood loss; the unordered categorical variables included the resection method and lymphadenectomy. The remaining variables were classified as dichotomized independent variables.

Table 1

Univariate analysis of 37 predictive variables

Items Category Group NA (n=1,048, 50%) Group A (n=1,048, 50%) Total (n=2,096) P value OR (95% CI)
Age (years) 58 (51.0, 64.0) 62 (56.0, 66.0) <0.001***
Gender Female 636 (56.99) 480 (43.01) 1,116 <0.001*** 1.827 (1.536–2.173)
Male 412 (42.04) 568 (57.96) 980
BMI (kg/m2) <18.5 36 (35.64) 65 (64.36) 101 0.002** 1
18.5–23.9 584 (48.67) 616 (51.33) 1,200 0.01* 0.584 (0.383–0.891)
24.0–27.9 347 (53.06) 307 (46.94) 654 0.001** 0.490 (0.317–0.757)
≥28 81 (57.45) 60 (42.55) 141 <0.001*** 0.410 (0.242–0.695)
Smoker No 987 (57.48) 730 (42.52) 1,717 <0.001*** 7.048 (5.273–9.421)
Yes 61 (16.09) 318 (83.91) 379
ASA I/II 782 (52.41) 710 (47.59) 1,492 0.001** 1.400 (1.157–1.693)
III/IV 266 (44.04) 338 (55.96) 604
Minimally invasive operation No 30 (17.34) 143 (82.66) 173 <0.001*** 0.187 (0.125–2.790)
Yes 1,018 (52.94) 905 (47.06) 1,923
Resection method Wedge resection 214 (73.04) 79 (26.96) 293 <0.001*** 1
Segmental resection 563 (60.15) 373 (39.85) 936 <0.001*** 1.795 (1.344–2.397)
Lobectomy 256 (33.20) 515 (66.80) 771 <0.001*** 5.449 (4.044–7.344)
Sleeve resection 10 (17.24) 48 (82.76) 58 <0.001*** 13.003 (6.275–26.942)
Total pneumonectomy 5 (13.16) 33 (86.84) 38 <0.001*** 17.878 (6.741–47.415)
Resection site Single lobectomy 987 (53.21) 868 (46.79) 1,855 <0.001*** 3.355 (2.475–4.549)
Translobar resection 61 (25.31) 180 (74.69) 241
Pleural adhesions No 913 (53.21) 803 (46.79) 1,716 <0.001*** 2.063 (1.639–2.598)
Yes 135 (35.53) 245 (64.47) 380
Lymphadenectomy Neglection 446 (61.94) 274 (38.06) 720 <0.001*** 1
Sampling 241 (59.21) 166 (40.79) 407 0.37 1.121 (0.875–1.437)
Dissection 361 (37.25) 608 (62.75) 969 <0.001*** 2.741 (2.247–3.345)
Blood loss ≤500 mL 1,042 (50.61) 1,017 (49.39) 2,059 0.001** 1
>500–900 mL 5 (17.86) 23 (82.14) 28 0.002** 4.713 (1.785–12.445)
>900 mL 1 (11.11) 8 (88.89) 9 0.048 8.197 (1.023–65.653)
Operation duration ≥3 h No 1,048 (55.51) 840 (44.49) 1,888 <0.001*** 0.445 (0.423–0.468)
Yes 0 (0.00) 208 (90.00) 208
Pathology Non-malignant 279 (62.00) 171 (38.00) 450 <0.001*** 1.861 (1.503–2.304)
Malignancy 769 (46.72) 877 (53.28) 1,646
NRS-2002 ≤1 score 919 (52.16) 843 (47.84) 1,762 <0.001*** 1
2 score 65 (34.39) 124 (65.61) 189 <0.001*** 2.080 (1.519–2.848)
≥3 score 64 (44.14) 81 (55.86) 145 0.06 1.380 (0.981–1.940)
Cancer history No 596 (43.50) 774 (56.50) 1,370 <0.001*** 0.467 (0.388–0.561)
Yes 452 (62.26) 274 (37.74) 726
Neoadjuvant therapy for lung cancer No 908 (53.00) 894 (47.00) 1,902 <0.001*** 4.341 (3.031–6.218)
Yes 40 (20.62) 154 (79.38) 194
Other lung diseases No 1,033 (51.06) 990 (48.94) 2,023 <0.001*** 4.035 (2.272–7.166)
Yes 15 (20.55) 58 (79.45) 73
Diabetes No 934 (50.40) 919 (49.60) 1,853 0.31 1.150 (0.880–1.503)
Yes 114 (46.91) 129 (53.09) 243
Coronary heart disease No 906 (50.96) 968 (49.04) 1,974 <0.001** 1.980 (1.349–2.906)
Yes 42 (34.43) 80 (65.57) 122
Hypertension No 752 (50.71) 731 (49.29) 1,483 0.31 1.102 (0.913–1.330)
Yes 296 (48.29) 317 (51.71) 613
Hyperlipidemia No 1,018 (49.98) 1,019 (50.02) 2,037 0.90 0.966 (0.575–1.621)
Yes 30 (50.85) 29 (49.15) 59
Cerebral infarction No 905 (50.96) 967 (49.04) 1,972 <0.001*** 1.958 (1.339–2.863)
Yes 43 (34.68) 81 (65.32) 124
Gastrointestinal esophagus disease No 1,012 (51.21) 964 (48.79) 1,976 <0.001*** 2.450 (1.642–3.655)
Yes 36 (30.00) 84 (70.00) 120
Hepatic disease No 1,033 (50.46) 1,014 (49.54) 2,047 0.006** 2.309 (1.250–4.265)
Yes 15 (30.61) 34 (69.39) 49
Urinary system disease No 1,016 (51.11) 972 (48.89) 1,988 <0.001*** 2.483 (1.627–3.787)
Yes 32 (29.63) 76 (70.37) 108
Skeletal system disease No 1,028 (51.22) 979 (48.78) 2,007 <0.001*** 3.623 (2.185–6.005)
Yes 20 (22.47) 69 (77.53) 89
PFT FEV1/FVC% ≥80% 985 (49.40) 909 (50.60) 1,994 0.02* 0.604 (0.402–0.910)
FEV1/FVC% <80% 63 (61.76) 39 (38.24) 102
LVEF ≥50% 1,042 (50.02) 1,041 (49.98) 2,083 0.78 1.168 (0.391–3.487)
<50% 6 (46.15) 7 (53.85) 13
VH Negative 1,018 (50.60) 994 (49.40) 2,012 0.008** 1.843 (1.170–2.905)
Hepatitis B or E positive 30 (35.71) 54 (64.29) 84
LFT Normal 961 (49.69) 961 (49.69) 1,934 0.33 0.851 (0.617–1.174)
ALT >50 U/L or AST >40 U/L 87 (53.70) 75 (46.30) 162
Scr Normal 1,038 (50.36) 1,023 (49.64) 2,061 0.01* 2.537 (1.212–5.308)
>111 μmol/L 10 (28.57) 25 (71.43) 35
GA <17.1% 970 (50.18) 963 (49.82) 1,933 0.57 1.098 (0.797–1.512)
≥17.1% 78 (47.85) 85 (52.15) 163
IGRA T-N <10 1,036 (50.56) 1,013 (49.44) 2,049 0.001** 2.983 (1.540–5.779)
T-N ≥10 12 (25.53) 35 (74.47) 47
D-dimer Mild (0.55–1.0 mol/L) 925 (52.53) 836 (47.47) 1,761 <0.001*** 1
Moderate (1.0–5.0 mol/L) 52 (52.53) 47 (47.47) 99 >0.99 1.000 (0.667–1.500)
Severe (>5.0 mol/L) 71 (30.08) 165 (69.92) 236 <0.001*** 2.571 (1.917–3.448)
HGB Normal 985 (52.37) 896 (47.63) 1,881 <0.001*** 2.652 (1.951–3.607)
<130 g/L 63 (29.30) 152 (70.70) 215
CRP ≤10 mg/L 1,028 (52.40) 934 (47.60) 1,962 <0.001*** 6.274 (3.869–10.173)
>10 mg/L 20 (14.93) 114 (85.07) 134
Traumatic hemothorax within 24 h No 1,041 (52.02) 960 (47.98) 2,001 <0.001*** 13.632 (6.282–29.580)
Surgical or medical intervention 7 (7.37) 88 (92.63) 95

Values are presented as median (P25, P75) or n (%). Mann-Whitney U test, *, P<0.05; **, P<0.01; ***, P<0.001. Group A, early postoperative hypoalbuminemia; Group NA, perioperative non-hypoalbuminemia. Other lung diseases: asthma, chronic obstructive pulmonary disease, emphysema, and bullae of lung; gastrointestinal system diseases: gastritis, duodenal ulcer, and gallbladder disease; skeletal system diseases: fractures, arthritis, and osteoporosis. ALT, alanine aminotransferase; ASA, American Society of Anesthesiologists; AST, aspartate aminotransferase; BMI, body mass index; CI, confidence interval; CRP, C-reactive protein; FEV1, forced expiratory volume in 1 second; FVC, forced vital capacity; GA, glycated albumin; HGB, hemoglobin; IGRA, mycobacterium tuberculosis γ interferon release experiment; LFT, liver function test; LVEF, left ventricular ejection fraction; NRS-2002, Nutritional Risk Screening 2002; OR, odds ratio; PFT, pulmonary function test; Scr, serum creatinine; VH, viral hepatitis.

Model training and validation

The dataset was randomly divided into training and test sets at a ratio of 8:2 and validated by five-fold stratified cross-validation. The training set was used to build the risk-prediction model of EPH, whose generalization performance was internally assessed by five-fold cross-validation (the predictions for each fold were generated using a model trained on the other four folds; no external data were used). In total, 37 candidate predictors were included as input features. The continuous and ordered categorical variables were treated as numeric; the nominal categorical variables were encoded with OneHotEncoder. All the features were standardized using StandardScaler. The preprocessed data were then supplied to the logistic regression (LR) model with L2 regularization to prevent overfitting. Model performance was assessed based on the area under the curve (AUC), accuracy, F1-score, precision, recall, and Brier score.

Interpretable analysis

SHapley Additive exPlanations (SHAP) were used to generate a feature-importance ranking and a summary plot. The mean absolute SHAP value indicates each variable’s contribution to the model, while the sign of the SHAP values in the summary plot revealed whether a feature was positively or negatively associated with EPH.

Statistics and computation

The non-normally distributed data are expressed as the median and interquartile range [M (IQR)], and the Mann-Whitney U test was used for comparisons between groups. The categorical data are presented as the number of cases (%), and the Pearson’s Chi-squared test was used for comparisons between groups. Both the ordered and unordered multi-categorical independent variables were analyzed by LR. All the statistical tests of the hypothesis were two-sided and performed at the 0.05 level of significance by SPSS 27. Python version 3.11.10 and scikit-learn version 1.5.2 were used to develop a ML model based on LR for the binary classification task.


Results

Patient demographics

In total, 2,096 patients who underwent 90-day postoperative follow-up at our center were enrolled in the study. The cohort comprised 1,048 patients and 1048 matched controls. In the case group, 84.7% of the patients (888/1,048) had mild hypoalbuminemia (ALB < lower limit of normal and ≥30 g/L), and 15.2% (160/1,048) had moderate hypoalbuminemia (ALB ≥20 to <30 g/L); no cases of severe hypoalbuminemia (ALB <20 g/L) were observed.

Univariate analysis

In the univariate analysis (Table 1), statistically significant differences were found between the control group and case group in terms of age (P<0.001), gender (P<0.001), BMI (<18.5 kg/m2 P=0.002; 18.5–23.9 kg/m2 P=0.01; 24.0–27.9 kg/m2 P=0.001; ≥28 kg/m2 P<0.001), smoker (P<0.001), NRS2002 (score 2 P<0.001), cancer history (P<0.001), neoadjuvant therapy for lung cancer (P<0.001), other lung diseases (P<0.001), coronary heart disease (P<0.001), cerebral infarction (P<0.001), gastrointestinal esophagus disease (P<0.001), hepatic disease (P=0.006), urinary system disease (P<0.001), skeletal system disease (P<0.001), pulmonary function test (PFT) (P=0.02), viral hepatitis (VH) (P=0.008), serum creatinine (Scr) (P=0.01), interferon-gamma release assay (IGRA) (P=0.001), D-dimer (>5.0 mol/L P<0.001), hemoglobin (HGB) (P<0.001), C-reactive protein (CRP) (P<0.001), American Society of Anesthesiologists (ASA) score (P=0.001), an operation duration ≥3 h (P<0.001), minimally invasive operation (P<0.001), the resection method (P<0.001), the resection site (P<0.001), pleural adhesions (P<0.001), lymphadenectomy (dissection: P<0.001), blood loss, pathology (P<0.001), and traumatic hemothorax within 24 h (P<0.001).

And no significant differences were found between the two groups in terms of the remaining variables, including diabetes (P=0.31), hypertension (P=0.31), hyperlipidemia (P=0.90), left ventricular ejection fraction (LVEF) (P=0.78), liver function test (LFT) (P=0.33), and glycated albumin (GA) (P=0.57).

Prediction model performance

The AUC of the training set was 0.8701 and that of the test set was 0.8543. An AUC value in this range (0.8≤ AUC <0.9) indicates that the classifier has a good ability to distinguish between the indicated classes, and a strong recognition ability. For binary outcomes, good discrimination means that a model can separate cases at high risk from those at low risk. The accuracy of the internal validation set was 0.771, indicating that the model correctly classified a high percentage of samples. Precision was 0.7947 and recall was 0.7309, indicating that the model correctly identified true positive and true negative cases of postoperative hypoalbuminemia. The F1-score was 0.7606, indicating the validity of the model (Table 2). The receiver operating characteristic (ROC) curves of the training and test sets illustrated the classification ability of the model (Figure 2). The confusion matrix revealed further classification details. The probability density plot provided valuable insights into the model’s performance by illustrating the distribution of predicted probabilities for positive and negative samples (Figure 3). In this plot, the distinct separation between the two curves suggested that the model effectively differentiates between the two classes. An overlap between the distributions would have indicated misclassifications. Overall, the model had high AUC, F1-scores, and recall rates, and showed strong predictive performance. Although the model performance was slightly lower in the test set than the training set, the model remained stable and had good generalization ability.

Table 2

Model summary

Item Parameter name Parameter value
Model parameter configuration Training-set ratio 0.8
Optimization algorithm lbfgs
Regularization L2
Maximum iterations 100
Dataset information Training set 1,676 (80.0%)
Test set 420 (20.0%)
Prediction set 0 (0.0%)
Missing data 0 (0.0%)
Total 2,096 (90.0%)
Model evaluation performance Train AUC 0.8701
Test AUC 0.8543
Accuracy 0.7710
Precision 0.7947
Recall 0.7309
F1-score 0.7606
Brier 0.1551

AUC, area under the curve.

Figure 2 ROC curves of the training and test sets. AUC, area under the curve; ROC, receiver operating characteristic.
Figure 3 Confusion matrix and probability density plot. neg, negative; pos, positive.

Explainability analysis

Using the LR model, we selected the top 20 features by mean |SHAP| value. Larger absolute values indicated a greater influence on EPH prediction. The importance matrix shows that an operating time ≥3 h was the strongest contributor. The red dots represent higher feature values, while the blue dots represent lower feature values (Figure 4).

Figure 4 SHAP summary and force plots. ASA, American Society of Anesthesiologists; BMI, body mass index; CRP, C-reactive protein; NRS-2002, Nutritional Risk Screening 2002; SHAP, SHapley Additive exPlanations.

Discussion

In clinical practice, considerations related to practicality and face validity favor simple, interpretable models. LR is the most commonly used method for short-term outcome prediction (e.g., the presence versus absence of disease) because it is easy to understand and implement. Compared with traditional logistic modeling, ML can analyze the large and diverse datasets common in the clinical arena, and uncover valuable patterns and associations (18,19). This single-center study leveraged perioperative data and a LR ML approach to develop a high-performance risk-prediction model for EPH after pulmonary surgery.

Predictors with proven or suspected causal relationships with the outcome should be prioritized for inclusion; this approach might increase the model’s generalizability. The absence of a causal relationship should not a priori exclude potential predictors. Predictors not causally related to the outcome but strongly associated with it might still contribute to model performance (20). Given that this study represents an initial stage of model development, we retained all the candidate predictors and addressed multicollinearity through L2 regularization rather than eliminating variables outright. Consequently, all 37 predictors, including multi-temporal data spanning the preoperative, intraoperative, and 24-hour postoperative periods, were incorporated into the model based on previous literature and clinical expertise, without restriction to those demonstrating statistical significance in the univariate analysis. The predictors comprised perioperative routine physical examination items for pulmonary surgery; thus, no additional invasive procedures were required, and no additional medical burden was placed on the patients.

Recent literature has reported that unless there is severe prior malnutrition, hypoalbuminemia in the acute phase of illness has no nutritional or metabolic component, and is largely the manifestation of other factors such as inflammation redistribution and serous fluid loss, which often occur individually or concurrently (21). Similarly, we found that surgical trauma significantly affected hypoalbuminemia. All the surgery-related predictors were found to be significantly associated with EPH in the univariate analysis. An operation duration ≥3 h, the resection method, the resection site, pleural adhesion, and hemothorax within 24 hours were among the top 20 contributors ranked by SHAP importance values. This indicates that the greater the surgical trauma (i.e., the wider the resection range and the more complex the surgical procedure), the more intense the systemic inflammatory response, and the higher the probability of developing EPH (22,23). This also suggests that surgical risks should be actively assessed under the premise of meeting guideline requirements, and appropriate surgical methods should be chosen to improve surgical precision and minimize bodily damage as much as possible. Preserving more lung parenchyma translates into a superior postoperative immune-nutritional profile, especially for lung cancer patients undergoing neoadjuvant therapy or young patients with stage I lung cancer (24).

Hypoalbuminemia is not a specific nutritional marker, as it is possible to die of starvation with a normal serum ALB concentration (21). Nevertheless, a patient’s baseline condition, particularly their nutritional status, and its effect on EPH should not be ignored.

When using the NRS-2002 scoring scale, patients aged 70 years or older automatically receive one additional point as an age-related risk factor (25). However, wide clinical variability exists: many patients under 70 years with worrisome nutritional status receive no extra points. Patients aged ≥70 years were not included in this study to reduce the influence of subjective indicators. Nevertheless, the results still demonstrated that NRS2002 scores ≥3 remained significant risk factors for EPH, with the risk spectrum extending to patients with NRS-2002 scores of 2. Further, our study also showed that an older age or a lower BMI were risk factors for the development of EPH. Currently, nutritional interventions, including nutritional menus, oral protein-rich nutritional supplementation, and electrolyte level correction, are only implemented for patients with NRS-2002 scores ≥3. The necessity of preoperative nutritional interventions for patients with NRS-2002 scores of 2 and the optimal duration of nutrition support for patients with NRS-2002 scores of 3 require further investigation.

At our center, patients with an NRS-2002 score ≥3—identified either before or after surgery—are immediately started on a standardized nutritional-care bundle that includes (brief overview) preoperative: (I) high-protein oral nutritional supplements (ONS): 1.5 g protein/kg/day with immunonutrients. (II) Abbreviated fasting: solids allowed up to 6 h before induction; 400–800 mL of a 12.5% clear-carbohydrate drink at 2–4 h (diabetics receive an IV glucose-free alternative). Post-operative: (I) early oral intake: clear fluid + ONS 500–1,000 ml on postoperative day (POD) 1; non-total-gastrectomy patients advance to soft solids by POD 2–3, ≥6 small meals/day. (II) Step-up algorithm: if oral intake <50% of target, continue ONS. If still <50% or nil per os for >7 days, start enteral nutrition at 10–20 mL/h and reach goal over 5–7 days. If enteral nutrition is insufficient or contraindicated, switch promptly to total parenteral nutrition using a ready-to-use three-chamber bag via central line. These interventions may also be selectively applied to patients with an NRS-2002 score of ≥2, for example, pre- or post-operative supplementation with high-protein ONS at 1.5 g/kg/day may be offered.

In addition, preoperative physical examination indicators and underlying diseases may also influence the development of EPH. In our study, among the top 20 features ranked by SHAP importance values, the risk factors also included male sex, smoking, malignant diseases, other lung diseases [e.g., chronic obstructive pulmonary disease (COPD), asthma, and emphysema], gastrointestinal system diseases (e.g., gastritis, duodenal ulcer, and gallbladder disease), and skeletal system diseases (e.g., fractures, arthritis, and osteoporosis), CRP (>10 mg/L), and D-dimer (>5.0 mol/L). These underlying diseases and behavioral traits were associated with chronic inflammation or malignant diseases, and many studies have also directly or indirectly explored the interplay among hypoalbuminemia, nutrition, and inflammation (21,26-30). Notably, the absence of statistical significance in the univariate analysis does not necessarily imply that a predictor is unimportant in reality; for example, factors such as diabetes, GA, LVEF, and LFT may not show a statistically significant difference due to existing interventions.

Poor perioperative glycemic control is closely associated with anastomotic leakage and surgical site infections, and nutritional intervention during the perioperative period is essential (31-33). In this study, no statistically significant difference was observed between diabetic cases (including those with GA ≥17.1%) and EPH, which was attributed to the implementation of comprehensive perioperative interventions such as a perioperative blood sugar management program, including medication interventions, a special diabetes diet plan, and diabetes-specific nutritional formulation management.

Cardiac or hepatic insufficiency can both cause hypoalbuminemia (34); however, patients with significantly impaired cardiac function rarely meet surgical criteria. Likewise, individuals whose transaminase levels exceed three times the upper limit of normal are usually referred to internal medicine department for optimization. Consequently, these high-risk groups were under-represented in our surgical cohort, which may explain why the univariate analysis failed to detect a statistically significant association.

Study limitations

This model was developed from a retrospective, single-center study. The 1:1 ratio of positive to negative samples might not reflect the true population distribution; at our tertiary center the incidence of postoperative hypoalbuminemia after pulmonary surgery was inherently low, so case matching might have yielded an overly optimistic model. Integrating larger-scale and multi-center datasets and conducting prospective studies may help improve the accuracy and general applicability of the predictions. A further limitation is that the model was developed exclusively to predict postoperative ALB decline in patients who already had normal preoperative levels.


Conclusions

In this study, an LR-based ML model demonstrated robust discriminative ability, accurately identifying elective pulmonary-surgery patients who were at high risk of developing EPH (serum ALB <35 g/L within 5 days of pulmonary surgery). The model provides solid support for timely preventive interventions and offers thoracic surgeons evidence-based guidance for personalized clinical decision-making.


Acknowledgments

None.


Footnote

Reporting Checklist: The authors have completed the TRIPOD reporting checklist. Available at https://jtd.amegroups.com/article/view/10.21037/jtd-2025-1-2620/rc

Data Sharing Statement: Available at https://jtd.amegroups.com/article/view/10.21037/jtd-2025-1-2620/dss

Peer Review File: Available at https://jtd.amegroups.com/article/view/10.21037/jtd-2025-1-2620/prf

Funding: None.

Conflicts of Interest: All authors have completed the ICMJE uniform disclosure form (available at https://jtd.amegroups.com/article/view/10.21037/jtd-2025-1-2620/coif). The authors have no conflicts of interest to declare.

Ethical Statement: The authors are accountable for all aspects of the work in ensuring that questions related to the accuracy or integrity of any part of the work are appropriately investigated and resolved. The study was conducted in accordance with the Declaration of Helsinki and its subsequent amendments. The study was approved by the Ethics Committee of Shanghai Chest Hospital (IRB No. IS24081) and individual consent was waived for this retrospective study.

Open Access Statement: This is an Open Access article distributed in accordance with the Creative Commons Attribution-NonCommercial-NoDerivs 4.0 International License (CC BY-NC-ND 4.0), which permits the non-commercial replication and distribution of the article with the strict proviso that no changes or edits are made and the original work is properly cited (including links to both the formal publication through the relevant DOI and the license). See: https://creativecommons.org/licenses/by-nc-nd/4.0/.


References

  1. Wiedermann CJ. Hypoalbuminemia as Surrogate and Culprit of Infections. Int J Mol Sci 2021;22:4496. [Crossref] [PubMed]
  2. Matsuoka K, Misaki N, Sumitomo S. Preoperative hypoalbuminemia is a risk factor for late bronchopleural fistula after pneumonectomy. Ann Thorac Cardiovasc Surg 2010;16:401-5.
  3. Pischik VG, Maslak OS, Obornev AD, et al. Risk factors and outcomes of prolonged air leak after pulmonary resections. Indian J Thorac Cardiovasc Surg 2019;35:564-8. [Crossref] [PubMed]
  4. Zhang W, Li S, Chen L, et al. Is low serum albumin associated with postoperative bronchopleural fistula in patients undergoing pulmonary resections? Interact Cardiovasc Thorac Surg 2019;29:291-294. [Crossref] [PubMed]
  5. Zhang S, Pang Q, Liu W, et al. Preoperative albumin can predict the risk of postoperative deep venous thrombosis in non-cardiac surgery. Front Med (Lausanne) 2025;12:1635218. [Crossref] [PubMed]
  6. Choi JW, Park JS, Lee CH. Genetically determined hypoalbuminemia as a risk factor for hypertension: instrumental variable analysis. Sci Rep 2021;11:11290. [Crossref] [PubMed]
  7. Valeriani E, Pannunzio A, Palumbo IM, et al. Risk of venous thromboembolism and arterial events in patients with hypoalbuminemia: a comprehensive meta-analysis of more than 2 million patients. J Thromb Haemost 2024;22:2823-33. [Crossref] [PubMed]
  8. Manolis AA, Manolis TA, Melita H, et al. Low serum albumin: A neglected predictor in patients with cardiovascular disease. Eur J Intern Med 2022;102:24-39. [Crossref] [PubMed]
  9. Li R, Zhu Y. Preoperative Hypoalbuminemia is Associated With Higher 30-day Mortality and Complications After Esophagectomy. Am Surg 2025;91:51-8. [Crossref] [PubMed]
  10. Randell Z, Martin B, Hendrickson N, et al. Hypoalbuminemia as a Predictor of Mortality, Disability, and Readmission in Patients Undergoing Spine Surgery: A Retrospective Analysis. Spine (Phila Pa 1976) 2023;48:1300-7. [Crossref] [PubMed]
  11. Ruangnapa K, Anuntaseree W, Saelim K, et al. Treatment and outcomes of chylothorax in children: 20-year experience of a single institute. J Thorac Dis 2022;14:3719-26. [Crossref] [PubMed]
  12. Cao F, Tong R. Analysis of Hypoproteinemia in Perioperative Period for Thoracic Surgery Cancer Patients. Chinese Journal of Clinical Thoracic and Cardiovascular Surgery 2012;19:447-8.
  13. Feng J. Discussion on Hypoproteinemia in Perioperative Thoracic Cancer Patients. Journal of Medical Information 2013;26:466-7.
  14. Sadr H, Nazari M, Khodaverdian Z, et al. Unveiling the potential of artificial intelligence in revolutionizing disease diagnosis and prediction: a comprehensive review of machine learning and deep learning approaches. Eur J Med Res 2025;30:418. [Crossref] [PubMed]
  15. Collins GS, Reitsma JB, Altman DG, et al. Transparent reporting of a multivariable prediction model for individual prognosis or diagnosis (TRIPOD): the TRIPOD statement. BMJ 2015;350:g7594. [Crossref] [PubMed]
  16. Freites-Martinez A, Santana N, Arias-Santiago S, et al. Using the Common Terminology Criteria for Adverse Events (CTCAE - Version 5.0) to Evaluate the Severity of Adverse Events of Anticancer Therapies. Actas Dermosifiliogr (Engl Ed) 2021;112:90-2. [Crossref] [PubMed]
  17. Riley RD, Ensor J, Snell KIE, et al. Calculating the sample size required for developing a clinical prediction model. BMJ 2020;368:m441. [Crossref] [PubMed]
  18. Goecks J, Jalili V, Heiser LM, et al. How Machine Learning Will Transform Biomedicine. Cell 2020;181:92-101. [Crossref] [PubMed]
  19. Ostberg NP, Zafar MA, Elefteriades JA. Machine learning: principles and applications for thoracic surgery. Eur J Cardiothorac Surg 2021;60:213-21. [Crossref] [PubMed]
  20. Efthimiou O, Seo M, Chalkou K, et al. Developing clinical prediction models: a step-by-step guide. BMJ 2024;386:e078276. [Crossref] [PubMed]
  21. Allison SP, Lobo DN. The clinical significance of hypoalbuminaemia. Clin Nutr 2024;43:909-14. [Crossref] [PubMed]
  22. Iwasaki A, Shirakusa T, Maekawa T, et al. Clinical evaluation of systemic inflammatory response syndrome (SIRS) in advanced lung cancer (T3 and T4) with surgical resection. Eur J Cardiothorac Surg 2005;27:14-8. [Crossref] [PubMed]
  23. Furák J, Németh T, Lantos J, et al. Perioperative Systemic Inflammation in Lung Cancer Surgery. Front Surg 2022;9:883322. [Crossref] [PubMed]
  24. Kamigaichi A, Mimae T, Amioka J, et al. Segmentectomy preserves better immune-nutritional status than lobectomy in patients with early-stage lung cancer. Eur J Cardiothorac Surg 2023;63:ezad019. [Crossref] [PubMed]
  25. Kondrup J, Allison SP, Elia M, et al. ESPEN guidelines for nutrition screening 2002. Clin Nutr 2003;22:415-21. [Crossref] [PubMed]
  26. Yanbaeva DG, Dentener MA, Creutzberg EC, et al. Systemic effects of smoking. Chest 2007;131:1557-66. [Crossref] [PubMed]
  27. Fairclough E, Cairns E, Hamilton J, et al. Evaluation of a modified early warning system for acute medical admissions and comparison with C-reactive protein/albumin ratio as a predictor of patient outcome. Clin Med (Lond) 2009;9:30-3. [Crossref] [PubMed]
  28. Wouters EF. Nutrition and metabolism in COPD. Chest 2000;117:274S-80S. [Crossref] [PubMed]
  29. Schols AM. The 2014 ESPEN Arvid Wretlind Lecture: Metabolism & nutrition: Shifting paradigms in COPD management. Clin Nutr 2015;34:1074-9. [Crossref] [PubMed]
  30. Tan T, Song A, Tang M, et al. The relationship between Glasgow Prognostic Score and hospital duration in patients with inflammatory bowel diseases. Asia Pac J Clin Nutr 2024;33:362-9. [Crossref] [PubMed]
  31. Ford KL, Prado CM, Weimann A, et al. Unresolved issues in perioperative nutrition: A narrative review. Clin Nutr 2022;41:1578-90. [Crossref] [PubMed]
  32. Takahashi M, Okada H, Kogaki M, et al. Short-term effects of preoperative nutritional intervention in lung surgery for malignant tumors: a single-center prospective study. Gen Thorac Cardiovasc Surg 2024;72:466-72. [Crossref] [PubMed]
  33. Witard OC, Hughes AK, Morgan PT, et al. Protein-based perioperative nutrition interventions for improving muscle mass and functional outcomes following orthopaedic surgery. Exp Physiol 2025;110:1802-9. [Crossref] [PubMed]
  34. Ghazal M, Khalife WI. Hypoalbuminemia in heart failure: pathophysiology, clinical implications, and management strategies. Heart Fail Rev 2025;30:1407-14. [Crossref] [PubMed]

(English Language Editor: L. Huleatt)

Cite this article as: Mao W, Gao H, Hu Y, Cheng X. Machine learning prediction model for early postoperative hypoalbuminemia after pulmonary surgery: a retrospective case-matched comparative study. J Thorac Dis 2026;18(1):38. doi: 10.21037/jtd-2025-1-2620

Download Citation