| Aim:The objective of this study is to analyze the various factors that impact the success rate of conservative treatment for ectopic pregnancy.Additionally,a machine learning model will be developed to predict treatment outcomes.Method:A total of 211 inpatients with ectopic pregnancy who underwent conservative treatment were selected at Guangzhou Women and Children’s Medical Center,Guangzhou Medical University between January 2020 and December 2021,based on specific inclusion and exclusion criteria.This study collected data on hospitalised patients with ectopic pregnancy,including 26 indicators such as age,height,weight,BMI,pregnancy history,ectopic pregnancy history,pelvic surgery history,menstrual cycle information,and symptoms such as lower abdominal pain and vaginal bleeding.The data also included the last h CG and progesterone levels measured before treatment.To predict the outcome of conservative treatment for ectopic pregnancy,we built seven classic machine learning models using R(version 4.2.3).These models include logistic regression,k-nearest neighbor,random forest,artificial neural network,gaussian kernel support vector machine,polynomial kernel support vector machine and linear kernel support vector machine.The accuracy of each model was evaluated and the performance of each model for predicting the outcome of conservative treatment of ectopic pregnancy was assessed by receiver operating characteristic curve(ROC curve)and area under ROC curve(AUC),PR curve,lift plot and gain plot.Result:Based on the analysis results of machine learning,the performance evaluation of random forest had the highest accuracy of 0.922,gaussian kernel support vector machine(0.906),k-nearest neighbor(0.891)and polynomial kernel support vector machine(0.891),logistic regression(0.875)and linear kernel support vector machine(0.875),artificial neural network(0.859),the accuracy decreases sequentially;random forest has the highest AUC value of 0.919,and logistic regression(0.902)and Gaussian kernel support vector machine(0.902),artificial neural network(0.899),linear kernel support vector machine(0.877),k-nearest neighbor(0.743)have decreasing AUC values sequentially.In addition,the following methods were used in this study: PR curves,lift plots and gain plots to evaluate the performance of each model in predicting conservative ectopic pregnancy outcomes,the best performance was obtained by the model constructed by random forest,so the random forest model was the best model for predicting conservative ectopic pregnancy outcomes in this study.Finally,from the prediction results of the random forest model,we found that:h CG value on the day of treatment(100%),h CG value on the third day of treatment(79.7%)and the last h CG value before treatment(59.3%)were the three factors most associated with conservative treatment of ectopic pregnancy patients.Conclusion:1.The random forest is the best model to predict the outcome of conservative treatment of ectopic pregnancy in this study,and the model can be further put into use in the future to help clinical decision-making.2.There are many factors that affect the outcome of conservative treatment of ectopic pregnancy,among which the h CG value on the day of treatment,the h CG value on the third day of treatment and the latest h CG value before treatment have the strongest correlation with the outcome;There is no strong correlation between presence or absence of vaginal bleeding,previous history of ectopic pregnancy and pelvic surgery history and outcome. |