# Unraveling Functional Dysphagia: A Game-Changing Automated Machine-Learning Diagnostic Approach
## 3 Results  
A sample swallow comparing a normal subject to a functional dysphagia patient is shown in Figures 1 and 2. Note the differences in the pattern of distension between the two subjects. The bolus arrives faster in the distal esophagus (a shorter T1) and luminal distension (luminal cross-sectional area) is smaller in the patient as compared to the normal subject. To evaluate the overall performance of the classification models, a hold-out approach was employed. The dataset was divided into two parts, a training set, and a test set, using five-fold cross-validation and an 80-20 train-test split. The five classification models (LR, RBF SVM linear, KNN, and random forest) were compared to determine which had the best performance using different evaluation metrics, such as accuracy, precision, and recall. The results are shown in Table 1. The significance of our approach lies in its inclusion of functional dysphagia as a distinct group within the classification framework. To obtain a visual insight into the distribution of some of the pressure and distension features, the averages of some features are shown in Figure 3.  
In seg 1, using only distension-related features (i.e., T1, peak distension, AUC distention, and STD of distension values), LR had the best overall results using only distension, with accuracy of 91.7%, precision of 92.86%, and recall of 91.7%. Next, using only pressure-related features (i.e., T2, peak pressure, AUC pressure, and STD pressure), KNN had the best overall results, with accuracy of 77.78%, precision of 83.33%, and recall of 77.78%. Finally, using both pressure- and distension-related features, KNN had the best overall results, with accuracy of 91.67%, precision of 93.45%, and recall of 91.67%.  
In seg 2, again using only distension features (i.e., CSA), linear SVM produced the best overall results, with accuracy of 86.1%, precision of 86.5%, and recall of 86.1%. Next,using only pressure parameters, KNN had the best overall results, with accuracy of 80.56%, precision of 81.43%, and recall of 80.56%. Finally, using both pressure- and distension-related features, random forest had the best overall results, with accuracy of 88.89%, precision of 89.68%, and recall of 88.89%.  
In seg 3, once again using only distension features (i.e., CSA), linear SVM produced the best overall results, with perfect accuracy of 100%, precision of 100%, and recall of 100%. Next, using only pressure-related features, RBF SVM had the best overall results, with accuracy of 77.78%, precision of 79.64%, and recall of 77.78%. Finally, using both pressure- and distension-related features, linear SVM had the best overall results, with accuracy of 94.44%, precision of 95.24%, and recall of 94.44%.  
Finally, in seg 4, using both contraction- and distension-related features, random forest produced the best overall results, with accuracy of 90.5%, precision of 91.1%, and recall of 90.5%. Using both pressure and distension features, it produced the highest results in the most distal segment. Feature importance was extracted using the Gini Index (GI) [50]. The two top features were T1 (GI = 0.22) and AUC distension (GI = 0.19) in the distal segment. Using only pressure parameters, RBF SVM had the best overall results, with accuracy of 75%, precision of 77.32%, and recall of 75%. Finally, using distension-related features, KNN had the best overall results, with accuracy of 96.11%, precision of 86.51%, and recall of 86.11%.  
Figure 3: T1 and T2 in all segments shown in panels **(a,b)**. In addition, pressure and distension features in the most proximal (**c**) and the most (**d**) distal segments of the esophagus in two groups are shown.