Two-stage cancer lifetime prediction model construction method and system

Through the two-stage cancer survival prediction model, combined with SVMSMOTE and random forest logistic regression classification model, the problem of low cancer survival prediction accuracy in the existing technology is solved, and more accurate survival prediction and treatment effect improvement is achieved.

CN119069140AActive Publication Date: 2024-12-03THE ACAD OF TIANJIN UNIV HEFEI
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202411193941.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-28
Publication Date
2024-12-03
Estimated Expiration
2044-08-28

AI Technical Summary

Technical Problem

The prior art has low accuracy in cancer survival prediction, especially the 5-year survival prediction prediction of high-mortality cancers, and there is a large generalization error in the single-stage logistic regression classification model.

Method used

The two-stage cancer survival prediction model was adopted. The first stage was used to predict whether patients could survive for 5 years using the IV cancer survival imbalanced classification method based on SVMSMOTE. The second stage was to predict the specific patients who could not survive for 5 years using the random forest logistic regression classification model. Survival time.

Benefits of technology

It improves the accuracy and treatment effect of cancer survival prediction, helps patients understand their own conditions more accurately and improve their quality of life.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119069140A_ABST
    Figure CN119069140A_ABST
Patent Text Reader

Abstract

The invention provides a two-stage cancer survival prediction model construction method and system, and the method comprises the steps: predicting whether a patient can survive for 5 years or not at a first stage through employing an effective logic regression classifier of an SVM SMOTE-based IV-stage cancer survival imbalance classification method, and at a second stage, predicting whether the patient can survive for 5 years or not; and if not, a random forest regression model is adopted to predict the specific survival time (in months) of the patient who cannot survive for five years. According to the research, effective and targeted prediction can be carried out on unique disease data of different patients, and the treatment effect and the life quality of the patients can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of cancer survival prediction, and in particular to a two-stage cancer survival prediction model construction method and system. Background Art

[0002] Cancer is a disease caused by the uncontrolled growth and spread of abnormal cells. These abnormal cells can invade surrounding normal tissues and form malignant tumors in different parts of the body. The causes of cancer are complex and varied, and are usually caused by the interaction of multiple factors such as genetic factors, environmental factors, and lifestyle factors. One of the reasons why cancer is so frightening is that most people are already feeling unwell when they find out they have cancer, which leads to cancer being diagnosed in the late stages, when treatment is not effective and survival rates are low. The prediction of a patient's expected survival and disease progression after having cancer is called cancer prognosis. Prognosis is usually assessed based on a variety of factors such as the type of cancer, stage, histological type, genetic factors, the patient's age and overall health. The good or bad prognosis is crucial for patients and doctors, and can affect treatment choices, lifestyle adjustments, and the development of rehabilitation plans. A good cancer prognosis usually means that the patient has a longer survival and better quality of life, may need less treatment, and has a lower risk of recurrence of the disease. A poor cancer prognosis means that the patient may face greater treatment challenges, a shorter survival, and a higher likelihood of disease progression.

[0003] Survivability prediction is one of the three major tasks of cancer prognosis, and its purpose is to provide patients with information about their expected survival status of the disease. So far, most studies have evaluated and reported the survival period, usually in a common time period of five years. This is because in the field of cancer treatment, the five-year survival rate is widely used to evaluate the prognosis of patients, that is, the patient is still alive five years (60 months) from the date of diagnosis. The five-year survival rate is an important indicator commonly used in medicine to evaluate the effectiveness of surgery and treatment. In the early days of medicine, the prediction of cancer survival rate was based on the clinical characteristics of malignant tumors and the doctor's medical experience. There was no unified standard and no scientific prediction theory, which made it impossible to make a relatively accurate judgment on the survival of different patients. Moreover, if different doctors had different predicted diagnostic results for the same patient, it would cause the patient to lack an accurate understanding of his own condition. Such uncertainty would inevitably lead to patients' concerns about their own condition, resulting in poor treatment effects. With the continuous development of science and technology, the prediction effect of cancer has become more accurate through the use of technologies such as machine learning and deep learning. For example, with the continuous improvement of the level of medical informationization, various medical information systems have been established, which can significantly improve the operational efficiency of hospitals; huge databases can collect and store millions of cancer data at the same time, and provide massive data to various types of machine learning models and deep learning models to predict the survival ability of different patients. In addition, the application of data mining technology in the field of healthcare is becoming more and more extensive, which makes it possible to further develop these underutilized medical data. Machine learning models, such as decision trees, logistic regression, support vector machines, linear regression, random forests, and neural networks, have been used as popular tools to identify useful patterns from the mining of patient data with the help of models trained by historical clinical data, and thereby predict the survival rate of cancer patients. The advantage of this is that it can make effective and targeted predictions for the unique disease data of different patients, thereby improving the survival rate of patients.

[0004] At present, machine learning methods have been widely used in cancer survival research to build prediction models to achieve more efficient and accurate medical decisions. Some previous studies have focused on improving the accuracy of cancer survival prediction models. Ali et al. summarized various data mining and machine learning methods that can be used to predict breast cancer survival. Their results showed that the accuracy of these methods is much higher than that of traditional statistical-based systems. Delen applied three popular machine learning methods, decision trees, artificial neural networks, and support vector machines, as well as one of the most commonly used statistical methods, logistic regression, to predict prostate cancer survival. In 1994, Burke compared some statistical models with the TNM (Tumor Node Metastasis) staging system, which has been used to predict the prognosis of cancer patients since the early 1960s. In predicting the 5-year breast cancer survival rate, the accuracy of several statistical models is much higher than that of the TNM staging system. Previous researchers have also proposed hybrid models. Khan et al. analyzed the feasibility of using fuzzy logic-based classifiers to predict the survival of cancer patients, and combined fuzzy set theory with decision trees to construct a weighted fuzzy decision tree (wFDT). Wang et al. combined the synthetic minority over sampling technique (SMOTE) with the particle swarm optimization algorithm (PSO) and one of three classification algorithms (logistic regression, k-Nearest Neighbor (KNN) and decision tree) to form a new breast cancer survival prediction classification method. Studies have shown that this hybrid algorithm can significantly improve the accuracy of breast cancer survival rate prediction.

[0005] In recent years, an integrated training method has been favored by researchers at home and abroad. This method trains a large number of weak classifiers (base learners) to learn models and combines their outputs with specific strategies to improve accuracy and efficiency. Edeki et al. applied six methods to the breast cancer data set in SEER, including logistic regression, decision tree, artificial neural network (multilayer perceptron) algorithm, support vector machine, AdaBoost, bagging and random forest. The results show that the overall performance level of each algorithm set depends on certain other algorithm features of each data algorithm set algorithm, such as the size of the data sample, quality characteristics and data representation. Random forest has relatively good accuracy in predicting cancer survival. Boughorbel et al. compared several models that affect the early prognosis of breast cancer in detail and found that random classification tree technology is at least better than boosted trees, partial differential equations and least squares models, generalized linear models (GLM), GLMNet, support vector machines, neural networks and K-nearest neighbors (KNN K-Nearest Neighbors) in evaluating the quality of model prediction and ranking. Random classification tree forest technology has obtained at least one best AUC (Area Under Curve) performance, which is an indicator for evaluating the performance of model prediction and ranking. Zolbanin et al. used logistic regression, artificial neural network, decision tree and random forest to generate prediction models to predict the overall survival rate of cancer comorbidities. The results showed that random forest had the highest accuracy.

[0006] Although the above studies have used a variety of models for prediction and achieved high accuracy. However, many models have low sensitivity due to the use of traditional classification methods to classify imbalanced data, especially for the prediction of 5-year survival rate of high-mortality cancers. Therefore, the characteristics of the data should also be considered to improve the overall prediction performance. So far, the prediction of survival time has proven to be very challenging because large generalization errors often occur when using single-stage logistic regression classification models. Summary of the invention

[0007] The technical problem to be solved by the present invention is to provide a method for constructing a high-precision prediction model in view of the low accuracy of cancer survival prediction in the prior art.

[0008] The present invention solves the above technical problems through the following technical means:

[0009] A two-stage cancer survival prediction model construction method comprises the following steps:

[0010] Step 1, build the dataset:

[0011] Step 1-1, the data set is from SEER;

[0012] Step 1-2, labeling the data set to construct a two-dimensional variable: survival months ≥ 60 months are labeled as 1, and survival months < 60 months are labeled as 0;

[0013] Step 1-3, preprocess the data of variables and records of the data set, and divide the data set: after basic preprocessing, retain a total of several records for classification experiments;

[0014] Step 2, training data set:

[0015] Step 2-1, use the Sigmoid function to train the data in step 1-2, compress and map the input feature values ​​so that the output value is between 0 and 1;

[0016] Step 2-2, convert the data item which is a text type categorical variable into a digital data variable, and remove the noise of the data at the same time; the categorical variables are divided into three categories: nominal variables, ordered variables and distance variables;

[0017] Step 3, construct and evaluate the logistic regression classification model: use the original unbalanced sample to process the unbalanced data, use the SMOTE algorithm to process the unbalanced data, and use the SVM STOME algorithm to process the unbalanced data to construct the logistic regression classification model respectively; after evaluation, the best logistic regression classification model is obtained;

[0018] Step 4: Build and evaluate the predictive logistic regression classification model:

[0019] Step 4-1, taking the 932 records with survival months less than 60 months in step 1-3 as the input data set, training and testing the data set;

[0020] Step 4-2: Build the predictive logistic regression classification model of each algorithm including random forest, ridge regression, LASSO regression, linear regression and Xgboost regression tree, and calculate MSE, MAE and R 2 The average value of the training set and the test set is determined by K-fold cross validation; after analyzing the experimental results, the average values ​​of MSE and MAE of random forest are the lowest;

[0021] Step 4-3: Build a single-stage model and a two-stage model of the random forest prediction logistic regression classification model, and calculate the MSE, MAE, and R 2 The average value of , the training set and the test set are determined according to K-fold cross validation;

[0022] Step 4-4, use the Gini index to evaluate the results of feature importance screening using random forest;

[0023] The variables with higher impact on survival rate were analyzed through signature analysis.

[0024] Furthermore, in steps 1-3, only cases with cancer stage IV were screened out. After preprocessing, a total of 1,065 records were retained for classification experiments, including 133 records with survival months ≥ 60 months and 932 records with survival months < 60 months, which were used for the random forest regression prediction stage experiment.

[0025] Furthermore, in step 2-1, a Sigmoid function is introduced to train the data in step 1-2:

[0026]

[0027] Among them, x i is the i-th data of the test set, is a p-dimensional column vector, m t and a are parameters to be determined;

[0028] After training with the Sigmoid function, the input feature values ​​are compressed and mapped so that the output value is between 0 and 1, thereby improving the expressiveness and accuracy of the model.

[0029] Furthermore, the SVM STOME algorithm is used to process unbalanced data, and its formula is shown in (2):

[0030]

[0031] Among them, L STOME (w,b,x,y)=exp(-y(w T x+b)), for samples that are correctly classified

[0032] L STOME (w,b,x,y)=exp(y(w T x+b)), for samples that are misclassified

[0033] C is a hyperparameter that controls the weights of correct and incorrect classifications.

[0034] Furthermore, in step 4-2, the 932 records of survival months < 60 months obtained after processing in steps 1-3 were input into the predictive logistic regression classification model of each algorithm, and the mean absolute error MAE, root mean error MSE and determination coefficient R 2 Three indicators were used to evaluate the effect of regression methods on predicting cancer survival;

[0035]

[0036] in, is the predicted value of the i-th sample, y i is the actual value, m pis the number of samples.

[0037] Furthermore, in step 4-4, the Gini index is used to evaluate the results of feature importance screening using random forest:

[0038] The calculation formula for the Gini index score of the feature is shown in (6), and the calculation formula for the importance index score of the variable is shown in (7):

[0039]

[0040] Among them, H represents H categories, q nh Represents the proportion of category h in node n, GI n1 and GI n2 Respectively represent the Gini index of the two new nodes after branching;

[0041] After feature analysis, the 12 best performing features were selected from the 15 features to analyze the variables with a higher impact on survival rate.

[0042] The present invention also provides a two-stage cancer survival prediction model construction system, comprising:

[0043] The data set construction module has the following specific execution process:

[0044] Step 1-1, the data set is from SEER;

[0045] Step 1-2, labeling the data set to construct a two-dimensional variable: survival months ≥ 60 months are labeled as 1, and survival months < 60 months are labeled as 0;

[0046] Step 1-3, preprocess the data of variables and records of the data set, and divide the data set: after basic preprocessing, retain a total of several records for classification experiments;

[0047] Training data set module, the specific execution process is:

[0048] Step 2-1, use the Sigmoid function to train the data in step 1-2, compress and map the input feature values ​​so that the output value is between 0 and 1;

[0049] Step 2-2, convert the data item which is a text type categorical variable into a digital data variable, and remove the noise of the data at the same time; the categorical variables are divided into three categories: nominal variables, ordered variables and distance variables;

[0050] Construct logistic regression classification model module: use original unbalanced samples to process unbalanced data, use SMOTE algorithm to process unbalanced data, and use SVM STOME algorithm to process unbalanced data to construct logistic regression classification models respectively; obtain the best logistic regression classification model after evaluation;

[0051] Construct a predictive logistic regression classification model module. The specific execution process is as follows:

[0052] Step 4-1, taking the 932 records with survival months less than 60 months in step 1-3 as the input data set, training and testing the data set;

[0053] Step 4-2: Build the predictive logistic regression classification model of each algorithm including random forest, ridge regression, LASSO regression, linear regression and Xgboost regression tree, and calculate MSE, MAE and R 2 The average value of the training set and the test set is determined by K-fold cross validation; after analyzing the experimental results, the average values ​​of MSE and MAE of random forest are the lowest;

[0054] Step 4-3: Build a single-stage model and a two-stage model of the random forest prediction logistic regression classification model, and calculate the MSE, MAE, and R 2 The average value of , the training set and the test set are determined according to K-fold cross validation;

[0055] Step 4-4, use the Gini index to evaluate the results of feature importance screening using random forest;

[0056] The variables with higher impact on survival rate were analyzed through signature analysis.

[0057] Furthermore, in step 2-1, a Sigmoid function is introduced to train the data in step 1-2:

[0058]

[0059] Among them, x i is the i-th data of the test set, is a p-dimensional column vector, m t and a are parameters to be determined;

[0060] After training with the Sigmoid function, the input feature values ​​are compressed and mapped so that the output value is between 0 and 1, thereby improving the expressiveness and accuracy of the model.

[0061] Furthermore, the SVM STOME algorithm is used to process unbalanced data, and its formula is shown in (2):

[0062]

[0063] Among them, LSTOME (w,b,x,y)=exp(-y(w T x+b)), for samples that are correctly classified

[0064] L STOME (w,b,x,y)=exp(y(w T x+b)), for samples that are misclassified

[0065] C is a hyperparameter that controls the weights of correct and incorrect classifications.

[0066] Furthermore, in step 4-2, the 932 records of survival months < 60 months obtained after processing in steps 1-3 were input into the predictive logistic regression classification model of each algorithm, and the mean absolute error MAE, root mean error MSE and determination coefficient R 2 Three indicators were used to evaluate the effect of regression methods on predicting cancer survival;

[0067]

[0068] in, is the predicted value of the i-th sample, y i is the actual value, m p is the number of samples.

[0069] The advantages of the present invention are:

[0070] The present invention uses a two-stage cancer survival prediction model. In the first stage, an effective logistic regression classifier based on SVMSMOTE IV stage cancer survival imbalance classification method is used to predict whether the patient can survive for 5 years in the first stage. In the second stage, a random forest logistic regression classification model is used to predict the specific survival time (in months) of patients who are not expected to survive for 5 years. This study can make effective and targeted predictions based on the unique disease data of different patients, which helps to improve the treatment effect and the quality of life of patients. BRIEF DESCRIPTION OF THE DRAWINGS

[0071] Figure 1 is a flow chart of a method in an embodiment of the present invention;

[0072] Figure 2 Schematic diagram of a Sigmoid function image in an embodiment of the present invention;

[0073] FIG3 shows the MAE, MSE, and R of various algorithms in Example 1 of the present invention. 2 Figure 3(a) is the comparison result of MAE value of each algorithm, Figure 3(b) is the comparison result of MSE value of each algorithm, Figure 3(c) is the comparison result of R 2 Value comparison result graph;

[0074] Figure 4 This is a graph of the importance ranking results of random forest features in Example 1 of the present invention. DETAILED DESCRIPTION

[0075] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in combination with the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0076] Example 1

[0077] A method for predicting cancer survival based on logistic regression classifier and random forest, comprising the following steps:

[0078] Step 1: Build a dataset

[0079] Step 1-1 Prepare the data set: The data set comes from the SEER (Surveillance, Epidemiology, and End Results) database of the National Cancer Institute of the United States. It is a resource created and maintained by the National Cancer Institute of the United States for collecting and publishing epidemiological and clinical data on cancer patients. The SEER database contains a large amount of cancer-related information, including personal characteristics of patients, disease characteristics, treatment data, and outcome data. These data can be used for epidemiological studies, disease trend analysis, survival rate calculation, treatment effect evaluation, and other studies.

[0080] In step 1-1, the data set contains 134 variables with complete data record descriptions, and can be obtained and used free of charge after signing a research data agreement. The present invention mainly extracts data from the lungs and bronchi for experiments;

[0081] Step 1-2 marks the extracted data set described in step 1-1: In step 1-2, the corresponding data variables (as shown in Table 1) are selected from the features according to the needs of the project of the present invention. Since the amount of data required by the present invention is not large and frequent data access is not required, the data can be copied and pasted into a CSV file for storage. The model constructed later by the present invention reads the data from the CSV file. In order to realize the algorithm prediction, all records with a survival time of more than 60 months since diagnosis are marked, that is, the survival months ≥ 60 months are coded as 1, and vice versa, the survival months < 60 months are coded as 0.

[0082] The above coded new variables are used as the target variables for classification, and the target variables for regression are the data items of survival months. Although the specific coding rules of the patient identification number in the SEER program are unknown, it has been found in previous studies that the patient identification number (Patient ID) contains some additional information about the patient, which is usually designated as related to certain characteristics or types of the patient.

[0083] Step 1-3 Data preprocessing: In order to improve accuracy and efficiency, the original lung cancer data set was preprocessed with variables and recorded data, and some variables were removed from the model. The present invention uses cases with diagnosis time from 2004 to 2015. In addition, records with undetermined diagnosis date and follow-up end date and records of causes of death other than primary cancer are also excluded, and only cases with cancer stage (AJCC Stage Group) belonging to stage IV (latest tumor) are screened out. After basic preprocessing, a total of 1065 records were retained for classification experiments, including 133 records with survival months ≥ 60 months, 932 records with survival months < 60 months, and 932 records with survival months < 60 months, which are used for experiments in the random forest regression prediction stage.

[0084] The data characteristics after rough screening are shown in Table 1:

[0085] Table 1 Data variable type list

[0086] Label variable Variable Description Variable abbreviation 1 Patient Id Patient number d 2 SEX gender sex 3 Age recode age age 4 Survival months Survival months months 5 Derived AJCC Stage Group, 6th ed(2004-2015) Tumor stage stage 6 Total number of in situ / malignant tumors for patient Number of tumors otal 7 CS tumor size (2004-2015) Lymphoma size size 8 ICD-O-3 Hist / behavior, malignant Pathological type histology 9 Grade Organizational hierarchy grade 10 CS extension (2004-2015) Degree of infiltration extension 11 CS lymph nodes (2004-2015) Lymphatic involvement nodes 12 CS mets at dx (2004-2015) Distant metastasis mets 13 RX Summ--Scope Reg LN Sur(2003+) Lymph node removal scope 14 Regional nodes examined(1988+) Number of lymph nodes examined examined 15 Regional nodes positive(1988+) Number of positive lymph nodes positive

[0087] Step 2: Training Dataset

[0088] Step 2-1 uses the Sigmoid function to train the data in step 1-2, and then obtains data that meets the requirements for training the model. The Sigmoid function is also called the Logistic function, and its value range is (0, 1). The formula of the Sigmoid function is shown in (1):

[0089]

[0090] Where e is the natural logarithm base and x is the input value.

[0091] In the actual prediction process, the Sigmoid function formula is shown in (2):

[0092]

[0093] Among them, x i is the i-th data of the test set, is a p-dimensional column vector, m t and a are parameters to be determined.

[0094] After training with the Sigmoid function, the input feature values ​​are compressed and mapped so that the output value is between 0 and 1, thereby improving the expressiveness and accuracy of the logistic regression classification model.

[0095] Step 2-2: Convert the data item from text type categorical variables to digital data variables, and remove noise from the data: Since some data are text type categorical variables, it is more conducive to model training to convert them into digital data variables. Categorical variables can be divided into three categories:

[0096] Nominal variables: There is no connection between them. For example, the sex attribute in Table 1 in Steps 1-3 can be processed using one-hot encoding.

[0097] Ordered variables: They are not completely independent of each other, but have certain connections, but cannot be transformed into each other through numerical operations, such as the organizational level attribute in Table 1 of steps 1-3;

[0098] Distant variables: can be transformed through mathematical calculations, such as the lymph node removal status (scope) attribute in the data. Two categories can be converted to each other by adding or subtracting a certain number, and can be processed using sequential coding.

[0099] Next, the three-times standard deviation principle is used for noise removal. The principle is that for data that obeys a normal distribution, under the 3σ principle, values ​​in a set of measured values ​​that deviate from the mean by more than three times the standard deviation will be defined as outliers. In this experiment, these outliers will be eliminated.

[0100] Step 3: Build and evaluate the logistic regression classification model

[0101] Building a logistic regression classification model includes: using the original unbalanced sample to process unbalanced data, using the SMOTE algorithm to process unbalanced data, and using the SVM STOME algorithm to process unbalanced data to respectively build a logistic regression classification model.

[0102] Sample imbalance refers to the situation where the number of training examples of different categories in a classification task varies greatly. Generally, if the sample category ratio (majority class VS minority class) is significantly greater than 1:1, it can be classified as sample imbalance. The data used in the present invention totals 1,065 items, including 133 records with survival months ≥ 60 months and 932 records with survival months < 60 months. The ratio is obviously unbalanced, so it is necessary to perform adaptive quota processing on the imbalanced data, because the classification boundary in the case of category imbalance will "invade" the area of ​​the minority class.

[0103] Step 3-1 uses the original unbalanced sample to process the unbalanced data by adjusting the classification threshold. By lowering the threshold (for example, lowering the threshold from 0.5 to 0.3 or lower), the model is more likely to predict the sample as a minority class (positive sample), thereby improving the detection ability of the minority class. By adjusting the threshold, the prediction results of the model can be changed, making the model pay more attention to minority class samples, improving the recall rate of the model, and thus improving the performance of the model on the unbalanced data set.

[0104] Step 3-2 uses the STOME algorithm to process unbalanced data. For each sample x in the minority class, the distance from it to all samples in the minority class sample set is calculated using the Euclidean distance as the standard to obtain its k nearest neighbors. A sampling ratio is set according to the sample imbalance ratio to determine the sampling multiplier N. For each minority class sample x, several samples are randomly selected from its k nearest neighbors. Assume that the selected nearest neighbors are For each randomly selected neighbor And the minority class sample x constructs a new sample according to formula (3):

[0105]

[0106] Step 3-3 uses the SVM STOME algorithm to process unbalanced data, and its formula is shown in (4):

[0107]

[0108] Among them, L STOME (w,b,x,y)=exp(-y(w T x+b)), for samples that are correctly classified

[0109] L STOME (w,b,x,y)=exp(y(w T x+b)), for samples that are misclassified

[0110] C is a hyperparameter that controls the weights of correct and incorrect classifications.

[0111] Step 3-4 Determine the evaluation index: Perform a five-fold cross validation on the data set in step 1-2. First, divide the data into 5 parts, select 4 parts as the training set Train, and the remaining 1 part as the test set Test. Train 5 classifiers and take the average of the test set results of the 5 classifiers as the final evaluation result of the model as shown in Table 2:

[0112] Table 2 Results of logistic regression model processing unbalanced data

[0113]

[0114] The experimental results show that the regression bias value of the logistic regression classification model constructed by the SVM STOME algorithm is low, the AUC value is close to 1, the classification effect is good, and the model prediction is more accurate.

[0115] Step 4: Build and evaluate the predictive logistic regression classification model

[0116] The 932 records of survival months less than 60 months in steps 1-3 were used to train and test the logistic regression classification model.

[0117] Step 4-1 Build predictive logistic regression classification models of major classic algorithms including: Random Forest, Ridge Regression, LASSO Regression, Linear Regression and Xgboost Regression Tree, and select from the mean absolute error (MAE mean absoluteerror), root mean error (MSE mean square error) and determination coefficient (R 2 coefficient of determination) to evaluate the regression method. is the predicted value of the i-th sample, y i is the actual value, m p is the number of samples, and the formulas of the three indicators are shown in (5)(6)(7):

[0118]

[0119]

[0120] R 2 It indicates the extent to which the model can explain the variability of the target variable and measures how well the model can predict new samples. It can be negative when the model is very poor.

[0121] Through experiments, the evaluation results of the three indicators of each algorithm are shown in Table 3:

[0122] Table 3 Evaluation results of each algorithm model

[0123]

[0124] In order to make a more intuitive comparison, the data are analyzed using a bar graph, as shown in Figure 3.

[0125] According to the experimental results, the random forest has the lowest MSE and MAE averages. 2 The average value is the highest, and the difference between the predicted survival time and the actual survival time using the random forest prediction model is not much. Since the months are divided by 10 during data processing, the average difference between the predicted value and the actual value is 9.235 months, which is the best prediction effect for cancer survival. 2The values ​​indicate that the random forest logistic regression classification model has the best explanation rate for the difference in survival months.

[0126] Step 4-2 Build a single-stage model and a two-stage model of the random forest prediction logistic regression classification model, and calculate the MSE, MAE, and R 2 The average value of , the training set and the test set are determined according to K-fold cross validation;

[0127] Through experiments, the evaluation results of the three indicators of the single-stage logistic regression classification model and the two-stage logistic regression classification model are shown in Table 4:

[0128] Table 4 5-fold cross validation results of the single-stage regression model and the two-stage regression model of random forest

[0129]

[0130] In this embodiment, the single stage refers to using random forest for training and testing. The double stage refers to using random forest for secondary modeling and then training a random forest logistic regression classification model. From the analysis of the experimental results, it can be concluded that the MAE and MSE of the double stage model are lower than those of the single stage model, while R 2 This shows that not only the average prediction error is reduced, but also the interpretability of the model is improved, thus verifying that the two-stage model is a better prediction model for cancer survival time than the single-stage model.

[0131] Step 4-3 uses the Gini index to evaluate the results of feature importance screening using random forest: the calculation formula of the feature's Gini index score (GI) is shown in (6), and the calculation formula of the variable importance index score (VIM variable importance measures) is shown in (7):

[0132]

[0133]

[0134] Among them, H represents H categories, q nh Represents the proportion of category h in node n, GI n1 and GI n2 Respectively represent the Gini index of the two new nodes after branching.

[0135] After feature analysis, the 12 best performing features were selected from the 15 features, as shown in the attached figure. Figure 4As shown. Among the features used in the logistic regression classification model, tissue grade and CS extension are the most important features. This result shows that in lung cancer, the degree of spread of cancer cells is closely related to low survival rate. Lymph node involvement (nodes), distant metastasis (mets) and lymph node tumor size (size) appear in the top 5 important variables, among which the variable of lymph node involvement (nodes) records the exact number of regional lymph nodes found to have metastasis by pathologists, and distant metastasis (mets) is also called malignant metastasis, which represents the degree of tumor cells from the original site to other parts of the body to continue to grow. And lymph node tumor size (size) records the specific size of the current state of the tumor. Lung cancer is a cancer with a high recurrence rate and metastasis rate. Metastasis is an important reason why lung cancer is difficult to cure after radical resection. Therefore, these three variables have a great impact on the survival time of lung cancer. Through the gender-related attributes sex_F and sex_M, we can find that gender does not have much impact on the survival of lung cancer, but we cannot deny that gender plays an important role in predicting the survival of other cancers. Then analyze the variables with a higher impact on survival rate.

[0136] In this embodiment, the data set obtained in step 1-2 (survival months ≥ 60 months are marked as 1, and survival months < 60 months are marked as 0) is input into the logistic regression classification model described in step 3, and the model is trained and evaluated according to the method of step 3 above, and the test set evaluation results PRE, REC, ACC, F1-score and AUC of each fold described in step 3-4 are retained, and the average value of the 5-fold cross validation is taken as the final result of each logistic regression classification model.

[0137] The calculation methods of accuracy (ACC), precision (PRE), recall (REC), and F1-score for each fold are as follows:

[0138]

[0139] Among them, TP, FP, TN and FN represent true positive, false positive, true negative and false negative, respectively.

[0140] According to the model evaluation method in step 3 above, five-fold cross validation was used to evaluate the model performance. The results are shown in Table 2 of step 3-4. The experimental data of the three logistic regression classification models showed that the regression bias value of the logistic regression classification model constructed by the SVM STOME algorithm was low, the AUC value was close to 1, the classification effect was better, and the model prediction was more accurate.

[0141] This embodiment proposes a two-stage IV cancer survival prediction model. The first stage is to predict whether the patient can survive for more than 5 years, and the second stage is to predict the exact survival time of patients who cannot survive for 5 years or more, in months. The first stage adopts the classification method of logistic regression considering unbalanced data. In the second stage, after using various classic algorithm models for prediction, the random forest two-stage regression prediction model widely used in various fields was finally selected to realize the prediction of cancer survival time. The model has good results by being verified on the test data set of this project, indicating that the method of predicting cancer survival based on logistic regression classifier and random forest has a high prediction accuracy.

[0142] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for constructing a two-stage cancer survival prediction model, characterized in that: The following steps are included: Step 1, build the dataset: Step 1-1, the data set is from SEER; Step 1-2, labeling the data set to construct a two-dimensional variable: survival months ≥ 60 months are labeled as 1, and survival months < 60 months are labeled as 0; Step 1-3, preprocess the data of variables and records of the data set, and divide the data set: after basic preprocessing, retain a total of several records for classification experiments; Step 2, training data set: Step 2-1, use the Sigmoid function to train the data in step 1-2, compress and map the input feature values ​​so that the output value is between 0 and 1; Step 2-2, convert the data item which is a text type categorical variable into a digital data variable, and remove the noise of the data at the same time; the categorical variables are divided into three categories: nominal variables, ordered variables and distance variables; Step 3, construct and evaluate the logistic regression classification model: use the original unbalanced sample to process the unbalanced data, use the SMOTE algorithm to process the unbalanced data, and use the SVM STOME algorithm to process the unbalanced data to construct the logistic regression classification model respectively; after evaluation, the best logistic regression classification model is obtained; Step 4: Build and evaluate the predictive logistic regression classification model: Step 4-1, taking the 932 records with survival months less than 60 months in step 1-3 as the input data set, training and testing the data set; Step 4-2: Build the predictive logistic regression classification model of each algorithm including random forest, ridge regression, LASSO regression, linear regression and Xgboost regression tree, and calculate MSE, MAE and R 2 The average value of the training set and the test set is determined by K-fold cross validation; after analyzing the experimental results, the average values ​​of MSE and MAE of random forest are the lowest; Step 4-3: Build a single-stage model and a two-stage model of the random forest prediction logistic regression classification model, and calculate the MSE, MAE, and R 2 The average value of , the training set and the test set are determined according to K-fold cross validation; Step 4-4, use the Gini index to evaluate the results of feature importance screening using random forest; The variables with higher impact on survival rate were analyzed through signature analysis.

2. The method for constructing a two-stage cancer survival prediction model according to claim 1, characterized in that: In the steps 1-3, only cases with cancer stage IV were screened out. After preprocessing, a total of 1065 records were retained for classification experiments, including 133 records with survival months ≥ 60 months and 932 records with survival months < 60 months, which were used for the random forest regression prediction stage experiment.

3. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: In step 2-1, the Sigmoid function is introduced to train the data in step 1-2: Among them, x i is the i-th data of the test set, is a p-dimensional column vector, m t and a are parameters to be determined; After training with the Sigmoid function, the input feature values ​​are compressed and mapped so that the output value is between 0 and 1, thereby improving the expressiveness and accuracy of the model.

4. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: The SVMSTOME algorithm is used to process unbalanced data, and its formula is shown in (2): Among them, L STOME (w,b,x,y)=exp(-y(w T x+b)), for samples that are correctly classified L STOME (w,b,x,y)=exp(y(w T x+b)), for samples that are misclassified C is a hyperparameter that controls the weights of correct and incorrect classifications.

5. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: In step 4-2, the 932 records of survival months < 60 months obtained after processing in steps 1-3 are input into the predictive logistic regression classification model of each algorithm, and the mean absolute error MAE, root mean error MSE and determination coefficient R 2 Three indicators were used to evaluate the effect of regression methods on predicting cancer survival; in, is the predicted value of the i-th sample, y i is the actual value, m p is the number of samples.

6. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: In step 4-4, the Gini index is used to evaluate the results of feature importance screening using random forest: The calculation formula for the Gini index score of the feature is shown in (6), and the calculation formula for the importance index score of the variable is shown in (7): Among them, H represents H categories, q nh Represents the proportion of category h in node n, GI n1 and GI n2 Respectively represent the Gini index of the two new nodes after branching; After feature analysis, the 12 best performing features were selected from the 15 features to analyze the variables with a higher impact on survival rate.

7. A two-stage cancer survival prediction model construction system, characterized in that: The following steps are included: The data set construction module has the following specific execution process: Step 1-1, the data set is from SEER; Step 1-2, labeling the data set to construct a two-dimensional variable: survival months ≥ 60 months are labeled as 1, and survival months < 60 months are labeled as 0; Step 1-3, preprocess the data of variables and records of the data set, and divide the data set: after basic preprocessing, retain a total of several records for classification experiments; Training data set module, the specific execution process is: Step 2-1, use the Sigmoid function to train the data in step 1-2, compress and map the input feature values ​​so that the output value is between 0 and 1; Step 2-2, convert the data item which is a text type categorical variable into a digital data variable, and remove the noise of the data at the same time; the categorical variables are divided into three categories: nominal variables, ordered variables and distance variables; Construct logistic regression classification model module: use original unbalanced samples to process unbalanced data, use SMOTE algorithm to process unbalanced data, and use SVM STOME algorithm to process unbalanced data to construct logistic regression classification models respectively; obtain the best logistic regression classification model after evaluation; Construct a predictive logistic regression classification model module. The specific execution process is as follows: Step 4-1, taking the 932 records with survival months less than 60 months in step 1-3 as the input data set, training and testing the data set; Step 4-2: Build the predictive logistic regression classification model of each algorithm including random forest, ridge regression, LASSO regression, linear regression and Xgboost regression tree, and calculate MSE, MAE and R 2 The average value of the training set and the test set is determined by K-fold cross validation; after analyzing the experimental results, the average values ​​of MSE and MAE of random forest are the lowest; Step 4-3: Build a single-stage model and a two-stage model of the random forest prediction logistic regression classification model, and calculate the MSE, MAE, and R 2 The average value of , the training set and the test set are determined according to K-fold cross validation; Step 4-4, use the Gini index to evaluate the results of feature importance screening using random forest; The variables with higher impact on survival rate were analyzed through signature analysis.

8. The two-stage cancer survival prediction model construction system according to claim 7, characterized in that: In step 2-1, the Sigmoid function is introduced to train the data in step 1-2: Among them, x i is the i-th data of the test set, is a p-dimensional column vector, m t and a are parameters to be determined; After training with the Sigmoid function, the input feature values ​​are compressed and mapped so that the output value is between 0 and 1, thereby improving the expressiveness and accuracy of the model.

9. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: The SVMSTOME algorithm is used to process unbalanced data, and its formula is shown in (2): Among them, L STOME (w,b,x,y)=exp(-y(w T x+b)), for samples that are correctly classified L STOME (w,b,x,y)=exp(y(w T x+b)), for samples that are misclassified C is a hyperparameter that controls the weights of correct and incorrect classifications.

10. The method for constructing a two-stage cancer survival prediction model according to claim 1, wherein: In step 4-2, the 932 records of survival months < 60 months obtained after processing in steps 1-3 are input into the predictive logistic regression classification model of each algorithm, and the mean absolute error MAE, root mean error MSE and determination coefficient R 2 Three indicators were used to evaluate the effect of regression methods on predicting cancer survival; in, is the predicted value of the i-th sample, y i is the actual value, m p is the number of samples.

Citation Information

Patent Citations

  • Cancer gene classification method and device based on two-stage depth feature selection and storage medium

    CN112926640A

  • Predictive test for identification of early stage nsclc patients at high risk of recurrence after surgery

    CN113711313A

  • Two-stage glioma patient lifetime prediction method based on nuclear magnetic resonance image

    CN114463325A

  • Cerebral infarction operation patient survival risk classification method based on machine learning

    CN115206527A

  • Construction method and application of pancreatic cancer prognosis staging system based on pathological morphology tag

    CN116543923A