Depression risk prediction method for senile chronic disease patients
By combining five machine learning algorithms and data balance techniques, we construct a depression risk prediction model for elderly patients with chronic diseases, and solve the problems of limited sample size and gender impact in existing studies, achieving higher accuracy of depression prediction and Gender-specific analysis.
Patent Information
- Application Number
- CN202411177724.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-26
- Publication Date
- 2024-12-24
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
When predicting the risk of depression in elderly patients with chronic diseases, the sample size is limited, the gender impact is not fully considered, and the important risk factors that cause depression in elderly people with chronic diseases are insufficient, resulting in insufficient model performance and gender-specific differences. .
Five machine learning algorithms (logistic regression, AdaBoost, random forest, k-nearest neighbor, support vector machine) are combined with three data balance technologies (Tomek Links, SMOTE, SMOTE+Tomek Links) to build a depression risk prediction model for elderly patients with chronic diseases. Through feature selection and data standardization processing, gender differences are considered to improve the predictive performance of the model.
It effectively improves the accuracy and balance accuracy of the prediction of chronic disease and depression in elderly patients, identify important predictors related to gender, and improves the generalization ability and prediction effect of the model.
Smart Images

Figure CN119174608A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of depression risk prediction, and in particular to a method for predicting depression risk in elderly patients with chronic diseases. Background Art
[0002] Late-life depression (LLD) is a common, recurrent, long-term mental disorder that occurs in people aged 60 years or older. The prevalence of LLD may be as high as 40% in hospitalized patients, 30% in nursing home patients, and 8-15% in community settings. Depression in the elderly often leads to other adverse consequences. Many advanced treatments have been used to treat depression, such as antidepressant drugs, transcranial magnetic stimulation, and psychotherapy. However, depression is often overlooked in the elderly, and many patients do not receive timely and regular treatment.
[0003] A Study on Global AGEing and Adult Health (SAGE) found that among 2508 patients with depression, 2098 (84%) did not report being diagnosed with depression or receiving treatment for depression. In addition, once older adults encounter vulnerability factors for depression, depression may recur throughout their lives. There are more than 300 vulnerability factors for LLD, such as age, physical health, cognitive function, gender, and education level. Therefore, it is crucial to develop models to predict the risk of depression and identify important predictors of depression in older adults.
[0004] Some studies have developed risk prediction models (RPMs) to estimate the risk of LLD based on relevant risk factors. However, current studies still have the following limitations.
[0005] First, most researchers have used limited risk factors and small sample sizes to develop RPMs for predicting depression. Second, although some RPMs have performed well in predicting depression in the elderly, little is known about the performance of these models and the important risk factors that lead to depression in the elderly with chronic diseases. And LLD involves not only emotional symptoms but also physical symptoms. Third, most current studies do not consider the effects of gender. Studies have shown that women experience depressive symptoms more frequently than men, and it is unclear whether these risk factors will change in sex-specific classification models for elderly people with chronic diseases. This difference may be because women's emotional health is strongly affected by biological changes related to their reproductive organs, social roles, and historical and cultural factors. Therefore, in the modeling process, the different effects of gender and chronic diseases should be considered separately. Summary of the invention
[0006] The present invention aims to develop RPMs for predicting depression and explore risk factors for depression in elderly people with chronic diseases. In addition, the present invention constructs models by gender to identify differences in important predictive factors between men and women.
[0007] To this end, the technical solution adopted in the present invention is as follows:
[0008] A method for predicting depression risk in elderly patients with chronic diseases, comprising the following steps:
[0009] Step 1: Establish an initial data set of elderly patients with chronic diseases. The data set contains seven types of variables, namely demographic variables, health status variables, lifestyle variables, psychological variables, drug variables, family status variables, and socioeconomic variables.
[0010] Step 2: preprocess the initial data set, including feature selection, data standardization, prediction task division, and data partitioning.
[0011] The feature selection is used to remove redundant and irrelevant feature variables, and the removal criteria are as follows:
[0012] (1) Variables missing in more than 20% of patients;
[0013] (2) variables with variance equal to 0;
[0014] (3) no statistical significance according to univariate analysis, i.e., p value ≥ 0.05;
[0015] The p-value is a statistical concept. If the p-value of a variable is ≥ 0.05, it means that the variable is not statistically significant.
[0016] The prediction task division is to divide the standardized data set into three groups for different prediction tasks, including all research samples in the entire data set (elderly group), male patients in all research samples (male group) and female patients in all research samples (female group);
[0017] Step 3: Build a depression risk prediction model for elderly patients with chronic diseases. The model consists of five machine learning algorithms and three resampling techniques. The resampling technique is used for data balance.
[0018] In step 4, the unbalanced data set and the balanced data processed by resampling technology were trained on five machine learning algorithms respectively, and 10-fold cross validation and grid search were used to evaluate the model performance when trained based on unbalanced and balanced data sets, and the best risk prediction model was selected based on the evaluation indicators of different machine learning models.
[0019] Furthermore, before the data standardization in step 2, the missing data are interpolated using a multiple interpolation method.
[0020] Furthermore, the Z-score algorithm is used to standardize the feature variables to balance the impact of different feature variables on the model.
[0021] Furthermore, the data division is to randomly divide the research samples of the three groups of prediction tasks into training sets and test sets with a division ratio of 7:3.
[0022] Furthermore, the step 3 uses three resampling techniques to solve the data imbalance problem, including Tomek Links, Synthetic Minority Oversampling Technique (SMOTE), and SMOTEOMEK, a method combining SMOTE and Tomek Links.
[0023] Furthermore, the step 3 uses five machine learning algorithms to construct a risk prediction model. The five machine learning (ML) algorithms are combined with the above three resampling techniques. The five ML algorithms are: logistic regression (LR), AdaBoost, random forest (RF), k-nearest neighbor (kNN) and support vector machine (SVM).
[0024] Furthermore, the evaluation indicators include accuracy, specificity, sensitivity, positive predictive value (PPV), negative predictive value (NPV), AUROC, AUPRC and balanced accuracy.
[0025] Compared with the prior art, the advantages of the present invention are:
[0026] (1) The present invention is a method for predicting depression in elderly patients with chronic diseases. The model is constructed using five ML algorithms and three data balancing methods. The best model can be selected based on the prediction performance evaluation indicators of different models.
[0027] (2) The data balancing technology proposed in the present invention effectively offsets the impact of data imbalance. The performance comparison of different ML models shows that the proposed data balancing method can improve the accuracy of predicting chronic depression in the elderly.
[0028] (3) The feature selection proposed in the present invention removes feature variables that are not related to depression, and considers the impact of gender on depression prediction, and establishes a gender-related machine learning prediction model. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0030] Figure 1 It is a structural diagram of the method of the present invention; DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0032] To achieve the above objectives, the present invention provides a method for predicting depression risk in elderly patients with chronic diseases, the method comprising:
[0033] Step 1: Establish an initial data set. The present invention uses a data set of 3959 elderly patients with chronic diseases, including the following seven types of variables, as shown in Table 1:
[0034] (1) Demographic variables, including gender, age, and country.
[0035] (2) Health status variables, including self-reported health status, physical pain status, etc.
[0036] (3) Lifestyle variables, including drinking, smoking, sleep duration, etc.
[0037] (4) Psychological variables, including cognitive impairment, life satisfaction, air satisfaction, etc. Air satisfaction was measured by asking participants whether they were satisfied with the air quality this year.
[0038] (5) Medication variables, measured by asking patients whether they use medications to treat chronic diseases.
[0039] (6) Family status variables, including grandchild care, nursing support, and living conditions.
[0040] (7) Socioeconomic variables, including education level, income, occupation, etc.
[0041] The resulting output variable of the model proposed in the present invention is depressive symptoms.
[0042] Step 2: preprocess the initial data set, specifically,
[0043] Step 201, feature selection is performed on the initial data set. By removing redundant and irrelevant feature variables, the model can be effectively prevented from overfitting. The specific criteria for removing redundant and irrelevant feature variables are as follows:
[0044] (1) Variables with missing values in more than 20% of participants;
[0045] (2) variables with variance equal to 0;
[0046] (3) There was no statistical significance according to univariate analysis (p value ≥ 0.05).
[0047] The data set removed 20 characteristic variables through the above criteria, leaving 37 characteristic variables. Among these research samples, 760 were assessed for depression. The average number of chronic diseases per person was 1.5. Most participants were between 60 and 69 years old. In addition, 54.7% of the participants were female, 23.9% had a history of falls, and 25.3% had received hospitalization. Among them, according to the univariate analysis results in Table 2, gender, age, marital status, physical pain, vision, fall experience, and education level were significantly associated with depression.
[0048] Step 202, use multiple interpolation method to interpolate missing data, and execute Z-score algorithm to standardize feature variables to balance the impact of different feature variables on the model and prevent overfitting of the model.
[0049] Step 203: After processing in step 202, the data set has 3959 patient research samples remaining, which are divided into three groups for different prediction tasks, including the entire research sample (elderly group), male patients in the entire research sample (male group), and female patients (female group). In order to avoid overfitting and test the generalization ability of the model prediction, each group of samples is randomly divided into a training set (70%) and a test set (30%).
[0050] Step 3: Build a depression risk prediction model for elderly patients with chronic diseases, specifically:
[0051] Step 301, using data balancing technology. The sample categories in the patient dataset are unbalanced, which will greatly affect the classification performance during the model training process. Several resampling techniques have been proposed to solve the problem of dataset imbalance, including Tomek Links, Synthetic Minority Oversampling Technique (SMOTE) and SMOTE+Tomek Links (SMOTEOmek).
[0052] Tomek Links is a common undersampling method that effectively avoids overfitting and bias in the majority samples by reducing noise and boundary lines in the majority class. SMOTE is a very effective oversampling method that has been widely used for imbalanced data. SMOTE Tomek is a popular hybrid method that has achieved good results in handling real-world tasks with imbalanced datasets.
[0053] Step 302, construct a risk prediction model. To construct the best risk prediction model, the present invention combines five machine learning (ML) algorithms with the three resampling techniques mentioned above. The five ML algorithms are: logistic regression (LR), AdaBoost, random forest (RF), k-nearest neighbor (kNN) and support vector machine (SVM).
[0054] LR is a widely used classical statistical method, and its good performance has been demonstrated in previous studies. AdaBoost is one of the most outstanding boosting algorithms, and has shown good performance in practical applications. The RF algorithm introduces a specific form of randomness, which improves its accuracy in various applications. kNN is the simplest and most popular supervised machine learning algorithm for regression and classification tasks. The SVM classifier constructs a linear decision surface by mapping the input vector to a high-dimensional feature space, thereby enhancing the generalization ability of the classifier.
[0055] Step 303, determine the model evaluation index. The model uses 10-fold cross validation and grid search to evaluate the performance when trained based on unbalanced and balanced data sets. The evaluation indicators include accuracy, specificity, sensitivity, positive predictive value (PPV), negative predictive value (NPV), AUROC, AUPRC and balanced accuracy.
[0056] Accuracy, specificity, sensitivity, PPV, and NPV are basic evaluation metrics, calculated using the confusion matrix. ROC is insensitive to systematic errors and can be used to evaluate the performance of various models on a standard, easy-to-interpret scale. PRC is increasingly used in machine learning research with imbalanced datasets. Balanced accuracy is the average of sensitivity and specificity. AUROC is the area under the ROC (receiver operating characteristic) curve, and AUPRC is the area under the precision-recall curve (PRC).
[0057] Combining three data balancing techniques with five machine learning algorithms, a prediction model for depression in elderly patients with chronic diseases was established, which was used to predict depression in the elderly group, male group, and female group, respectively. The hyperparameters of the optimal machine learning model for depression prediction in different groups are experimentally verified as shown in Table 3, and the predictions for the elderly group, male group, and female group are shown in Table 4, Table 5, and Table 6, respectively. Overall, after balancing the data, most classifiers achieved high accuracy in terms of PPV. In addition, the RF-SMOTE model performed best in predicting depression in elderly people with chronic diseases (accuracy: 0.891, AUROC: 0.957, balanced accuracy: 0.811; sensitivity: 0.875).
[0058] The relationship between feature variables and depression may vary by gender. Therefore, the present invention constructs RPM for different genders. It can be seen from Tables 5 and 6 that the model trained on the unbalanced data set already has good accuracy and AUROC values. When the model is combined with the three data balancing techniques, better balanced accuracy, sensitivity and AUPRC values can be obtained, especially the kNN-SMOTETomek model trained on elderly male data. Compared with other models, this model performs best in predicting depression (accuracy: 0.828, AUROC: 0.825, balanced accuracy: 0.831). In addition, the RF-SMOTE model is the best model for predicting depression in elderly women (accuracy: 0.879, AUROC: 0.928, balanced accuracy: 0.839).
[0059] Table 1 Independent variables
[0060]
[0061]
[0062]
[0063]
[0064] Table 2 Univariate analysis of sample characteristic variables
[0065]
[0066]
[0067]
[0068]
[0069]
[0070]
[0071]
[0072] Table 3 Hyperparameters of the optimal machine learning model for depression prediction in different groups
[0073]
[0074]
[0075] Table 4 Evaluation indicators of different models for predicting depression in the elderly
[0076]
[0077]
[0078]
[0079] Table 5 Evaluation indicators of different models for predicting depression in the male group
[0080]
[0081]
[0082]
[0083] Table 6 Evaluation indicators of different models for predicting depression in the female group
[0084]
[0085]
[0086] The present invention is a method for predicting depression in elderly patients with chronic diseases. Five ML algorithms and three data balancing methods are used to build models, and the best model is selected according to the prediction performance evaluation indicators of different models. The data balancing technology proposed in the present invention effectively offsets the impact of data imbalance. According to the performance comparison of different ML models, the proposed data balancing method can improve the accuracy of predicting depression in elderly patients with chronic diseases. In addition, the present invention also uses feature selection to remove feature variables that are not related to depression, and considers the impact of gender on depression prediction, and establishes a gender-related machine learning prediction model.
[0087] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0088] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for predicting depression risk in elderly patients with chronic diseases, characterized in that: The following steps are included: Step 1: Establish an initial data set of elderly patients with chronic diseases. The data set contains seven types of variables, namely demographic variables, health status variables, lifestyle variables, psychological variables, drug variables, family status variables, and socioeconomic variables. Step 2: preprocess the initial data set, including feature selection, data standardization, prediction task division, and data partitioning. The feature selection is used to remove redundant and irrelevant feature variables, and the removal criteria are as follows: (1) Variables missing in more than 20% of patients; (2) variables with variance equal to 0; (3) no statistical significance according to univariate analysis, i.e., p value ≥ 0.05; The p-value is a statistical concept. If the p-value of a variable is ≥ 0.05, it means that the variable has no statistical significance. The prediction task division is to divide the standardized data set into three groups for different prediction tasks, including all research samples in the entire data set (elderly group), male patients in all research samples (male group) and female patients in all research samples (female group); Step 3: Build a depression risk prediction model for elderly patients with chronic diseases. The model consists of five machine learning algorithms and three resampling techniques. The resampling technique is used for data balance. In step 4, the unbalanced data set and the balanced data processed by resampling technology were trained on five machine learning algorithms respectively, and 10-fold cross validation and grid search were used to evaluate the model performance when trained based on unbalanced and balanced data sets, and the best risk prediction model was selected based on the evaluation indicators of different machine learning models.
2. The method for predicting depression risk in elderly patients with chronic diseases according to claim 1, characterized in that: Before the data standardization in step 2, the missing data are interpolated using the multiple interpolation method.
3. The method for predicting depression risk in elderly patients with chronic diseases according to claim 2, characterized in that: The Z-score algorithm is used to standardize feature variables to balance the impact of different feature variables on the model.
4. The method for predicting depression risk in elderly patients with chronic diseases according to claim 3, characterized in that: The data division is to randomly divide the research samples of the three groups of prediction tasks into training sets and test sets, with a division ratio of 7:
3.
5. The method for predicting depression risk in elderly patients with chronic diseases according to claim 1, characterized in that: The step 3 uses three resampling techniques to solve the data imbalance problem, including Tomek Links, Synthetic Minority Oversampling Technique (SMOTE), and SMOTEOMEK, a method combining SMOTE and TomekLinks.
6. The method for predicting depression risk in elderly patients with chronic diseases according to claim 5, characterized in that: The step 3 uses five machine learning algorithms to construct a risk prediction model. The five machine learning (ML) algorithms are combined with the three resampling techniques mentioned above. The five ML algorithms are: logistic regression (LR), AdaBoost, random forest (RF), k-nearest neighbor (kNN) and support vector machine (SVM).
7. The method for predicting depression risk in elderly patients with chronic diseases according to claim 6, characterized in that: The evaluation indicators include accuracy, specificity, sensitivity, positive predictive value (PPV), negative predictive value (NPV), AUROC, AUPRC and balanced accuracy, where AUROC is the area under the ROC (receiver operating characteristic) curve, and AUPRC is the area under the precision-recall curve (PRC).
Citation Information
Patent Citations
Construction method of disease risk prediction model and related equipment
CN113223708A
Depression rating system and method based on machine learning
CN114649075A
Method for identifying influence depression level by using machine learning
CN118430822A
Apparatus and method for inspecting lead tab
KR1020240166642A
