An Intelligent System for Thyroid Dysfunction Prediction

The prediction of thyroid diseases has become increasingly important in recent years. The feature engineering part is generally less studied in existing approaches than model optimization. To circumvent these restrictions, feature engineering for machine learning (ML) and deep learning models are examined in our research. This paper proposes a system to predict thyroid dysfunction. A model comprises three stages: preprocessing of the data, selection of features, and classification. A standard scalar normalizes the data after filling missing values with mean values. A Deep Neural Network (DNN) is utilized for classification, and the Improved Salp Swarm Algorithm (ISSA) is used for feature selection. Finally, accuracy is utilized to estimate the system proposed. The UCI thyroid illness datasets are used in our investigation. In experiments with the DNN model, deep learning classifiers based on selected features produce the highest accuracy of 99.68%. The model proposed has superior performance compared to state-of-the-art methods.


I. INTRODUCTION
N the healthcare industry, computational biology is being utilized to develop new treatments.By doing so, we could gather the patient information that had been kept to predict illness in the past.Various clever prediction algorithms are available for the early-stage detection of the illness.Many datasets exist in the medical information system, but no intelligent algorithms can quickly analyze diseases.ML algorithms are essential in the long run for resolving the challenging nonlinear issues in creating a prediction model.Any disease prediction model must prioritize the characteristics chosen from the various datasets and utilized to classify healthy patients as accurately as possible.In such a situation, a healthy patient could receive unnecessary treatment as a result of misclassification.Thus, it is extremely important to foresee any health problem associated with thyroid disease [1,2].
The thyroid is a neck-based endocrine gland that produces hormones (FT3 and FT4) that are then released into the circulation.In addition to controlling heart rate and body temperature, thyroid hormones are responsible for regulating metabolism, which is how the body utilizes and absorbs nutrition [3].Significant problems can arise from an overactive or underactive thyroid gland (hyperthyroidism with excessive hormones or hypothyroidism with decreased hormones) [4].In addition, the thyroid gland may become inflamed (thyroiditis) or expand due to one or more tumors growing inside (multinodular goiter, nodules).Cancerous tumors can sometimes be found in these nodules.Due to this, treating thyroid issues is a critical issue [5].
This research presents a model for predicting thyroid dysfunction.The model is divided into three stages: feature selection, data preparation, and classification.The data is handled by substituting the mean value for any missing values before being normalized using a standard scalar.Both the deep neural network (DNN) and the improved Salp Swarm algorithm (ISSA) are used in the classification process.Finally, the model is assessed using F-measure, accuracy, and precision.
The paper is arranged as follows: the related work is demonstrated in section II, the theoretical background is discussed in section III, the proposed method is discussed in section IV, the results are discussed in section V, and the conclusion is outlined in section VI.

II. RELATED WORK
Numerous studies have examined how hormonal parameters and patient data, such as age and gender, can be used to identify thyroid diseases.The most notable difference is that some studies use machine learning models for prediction and classification, whereas others use deep neural networks.K. Shankar [6], proposed an algorithm utilizing kernelbased classifiers and optimal feature selection to classify I VOLUME 23(2), 2024 thyroid diseases.Using multi-kernel support vector machines, the authors enhanced the classifying process by using improved gray wolf optimization to enhance feature selection.The suggested thyroid prediction results in specificity, sensitivity, and accuracy of 94.5%, 99.05%, and 97.49% compared to the existing methods.
T. Alyas [7] used several algorithms of machine learning, such as random forests, decision trees, KNNs, and artificial neural networks to optimize the prediction of disease depending on the parameters of the dataset.For the classification, the dataset has also been manipulated to make accurate predictions.Several datasets were classified based on unsampled and sampled data for better comparisons.After dataset manipulation, the RF algorithm attained the highest accuracy, equal to 91% specificity and 94.8% accuracy.
G. Chaubey [8] predicted and assessed their accuracy using three different techniques: decision trees, logistic regression, and KNN algorithms.The thyroid data set from UC Irvin knowledge discovery in the databases archive was used by the machine learning repository for this.The highest accuracy achieved by KNN is 96.875%.
I. Ioniţă and L. Ioniţă [9] examined and contrasted the Radial Basis Function Network, Multilayer Perceptron, Decision Tree, and Naive Bayes classification models.All of the classification models mentioned above have substantial accuracy, according to the data; the decision tree model has the best classification rate.The UCI machine learning repository supplied the dataset to develop and evaluate the classifier.The highest accuracy achieved is 96.5% with the decision tree algorithm.
S. Sankar [10] considered the knowledge discovery dataset from UC Irvin.This research suggests using the XGBoost algorithm to forecast thyroid illness precisely.A comparison is made between the effectiveness of the proposed XGBoost algorithm and the logistic regression, decision tree, and knearest Neighbor (kNN) approaches.We compare and evaluate the performance of all four methods.The accuracy of the proposed XGBoost achieves 98.59%, KNN has an accuracy of 96.875%, a Decision tree -87.5%, and logistic regression -81.25%.

A. DATASET
The UCI thyroid illness datasets are used in our investigation.The UCI machine learning repository has several datasets related to thyroid conditions [11].There are 9172 sample observations in the dataset, and 31 characteristics are used to represent each sample.

B. IMPROVED SALP ALGORITHM (ISSA)
Salps have a translucent barrel-shaped body and are members of the Salpidae family [12].A salp's shape is seen in Figure 1(a).Salps frequently group to create salp chains in deep waters.Figure 1(b) shows an illustration of this chain.
Although the primary cause of this behavior is still unclear, some scientists think it is done to enhance mobility through quickly synchronized adjustments and feeding [13].A population is first split into two groups, leaders and followers, in order to mathematically describe the salp chains.Salps in the head of a chain are known as leaders, while the other salps are known as followers.These salps are called so because the leader leads the followers, and the swarm follows each other, either indirectly or directly following the leader.The salp's position is specified in an n-dimensional search space, where n is the number of variables in a given issue, just like in other swarm-based algorithms.Hence, a twodimensional matrix named x contains the positions of every salp [14,15].
Ref [14] suggests using the following equation to modify the leader's position: where: Fj is a position of a food supply in a jth dimension, ubj denotes an upper bound of a jth dimension, lbj denotes a lower bound, c3, c1, and c2 are random integers, and x1 j presents a position of a first salp (leader) in a jth dimension.The leader merely modifies its location with relation to food supply, as demonstrated by Equation (1).Most crucial factor in SSA is the coefficient c1, which balances the definitions of exploration and exploitation [14]: where: L is a maximum number of iterations, l is a current iteration.
Random integers evenly produced inside the interval [0,1] comprise the parameters c2 and c3.They specify the step size and whether the subsequent location in the jth dimension should be toward negative or positive infinity.
Using Newton's law of motion, the below equations are used to modify the followers' positions: where: i ≥ 2,  indicates ith follower salp position in jth dimension, t is the time, v0 is the initial speed, and a = v final v0, where v = x−x0t.
Since optimization involves iterations, the difference between them equals 1.With v0 = 0, this equation may be written as follows: where: the position of the ith follower salp in the jth dimension is indicated by  and i ≥ 2. It is possible to mimic the salp chains using Equations ( 1) and ( 4).
Figure 2 shows the block diagram of the SSA algorithm.The SSA method begins approximating the global optimum by starting several salps at random points, as this picture illustrates.Next, it determines which salp has the highest fitness by calculating each salp's fitness and designating the best salp's location as the source food that the salp chain will pursue by placing it in variable F. In the meanwhile, Equation ( 2) is used to modify the coefficient c1.Equation ( 1) is utilized to update the location of the leading salp for every dimension, while Equation ( 4) is used to update the position of the follower salps.Salp will be returned to the borders if any of it leaves the search area.With the exception of initialization, every step above is carried out repeatedly until a final requirement is satisfied [14].SSA keeps the optimal answer in the food source variable.As such, the process of utilizing search space is very competitive.Similar to several other optimization techniques, SSA continues to need help with poor convergence speed and local stagnation.To overcome these issues, Ref [16] suggested an improved SSA named ISSA.The ISSA improvements are as follows.Firstly, an inertia weight w ∈ [0, 1] is presented in SSA.During the search, this parameter quickens the convergence pace.To get around local fixes, it also strikes a balance between exploration and exploitation capabilities.During the search, this parameter quickens the convergence pace.To get around local fixes, it also strikes a balance between exploration and exploitation capabilities.Equation ( 5) illustrates the update formula [15]:

𝑥 [𝑘 + 1] = 𝑤 𝑥 [𝑘] + 𝑐 𝑥 [𝑘]) .
(5) Lastly, the algorithm convergence rate could be more stable but often slow.Consequently, the OBL method is used [17,18].By using this method, the algorithm may be brought closer to the global optima, giving it greater flexibility to explore the search space and accelerating its convergence to the ideal value.Mathematically, OBL can be indicated as in (6): The Improved SSA is illustrated in Figure 3. DNNs are a subset of AI, also known as deep learning, which, according to John McCarthy, the computer scientist who invented the phrase in the 1950s, is "the engineering and science of creating intelligent machines with the ability to attain goals like humans" [19,20].
Deep learning is a subdomain of neural networks in which neural networks include more than three layers, i.e., more than one hidden layer.The normal number of network layers utilized in deep learning nowadays ranges from five to over a thousand.Deep neural networks (DNNs) are used in this article to indicate the neural networks utilized in deep learning.Deep neural networks (DNNs) may learn higher-level characteristics with greater abstraction and complexity than shallower neural networks.Utilizing DNNs to process visual data is an illustration of this principle [21].

D. EVALUATIONJ METRICS
As part of the evaluation of any deep learning model, certain key classification metrics such as Accuracy, Recall, F1-score, and precision are computed.This is calculated by adding up the True Positives, False Positives, True Negatives, and False Negatives [22,23].
In math, accuracy refers to the percentage of accurate predictions made by a model.Among all metrics, it is the most important one because it indicates whether the model is successful.It is computed as follows [24,25]:

IV. PROPOSED METHOD
In the first step, the dataset is processed.In the preprocessing module, the dataset is checked for missing values and then replaced with the mean value, and normalization is performed in this module.After preprocessing, the dataset is partitioned into two parts: the testing and training dataset.
In the second step of the framework, we performed feature selection using the improved Salp algorithm (ISSA).The DNN is used to predict thyroid dysfunction at the classification step.Then, the model is evaluated using accuracy, precision, and recall measures.Figure 4 illustrates the proposed method.

V. RESULTS AND DISCUSSION
This section describes the research results on thyroid illness prediction using deep learning and an optimization technique.We describe the outcomes of the feature selection strategy using ISSA and deep learning models.We divided the dataset into testing and training sets in a 75:25 ratio, using 75% of the data for model training and 25% for model testing.
After data splitting, we processed the data by replacing the missing values with the mean value.Then, the data is normalized.We use ISSA for feature selection, then, deep learning model with their best hyperparameter settings.Models are trained using significant characteristics chosen using feature selection methods and then tested with 25% of the data.We evaluate models in terms of accuracy.Table 2 shows the results of the proposed ISSA-DNN model.Figure 8 demonstrates the results compared with the related work.[6] used optimal feature selection and KNN for classification and achieved an accuracy of 97.49%.T. Alyas [7] utilized RF for classification and attained an accuracy of 94.8%, I. Ioniţă and L. Ioniţă [9] achieved 96.5% with the decision tree, G. Chaubey [8] achieved 96.875% with the KNN algorithm, whereas S. Sankar [10] achieved 98.59% with XGBoost.The proposed ISSA-DNN outperformed the previous work with an accuracy score of 99.68%.

VI. CONCLUSIONS
Thyroid disease detection has become a major medical concern with an alarming rise in recent years, necessitating the use of effective computerized prediction algorithms.Model optimization and feature engineering are the main topics of current research; feature selection needs to be better explored.Feature selection and machine learning models are combined in this study to overcome these limitations.In this paper, a thyroid dysfunction prediction model is presented.The system is composed of three stages: data preprocessing, feature selection, and classification.The data is processed by filling missing values with mean values and then normalizing them using a standard scalar.ISSA is utilized for feature selection, and deep neural networks (DNN) are used for the classification process.Finally, the system is evaluated with accuracy.Results show that deep learning classifier-based selected attributes tend to achieve the highest accuracy of 99.68% when utilized with the DNN model.According to performance comparisons with the state-of-the-art approach, the proposed approach performs better than existing approaches.

Figure 2 .
Figure 2. The block diagram of the SSA[14]

Figure 4 .
Figure 4. Proposed method design Algorithm 1 illustrates the proposed ISSA-DNN algorithm.

Figure 6 .
Figure 6.The loss results of the DNN model

Figure 7 .
Figure 7.The accuracy of the DNN model

Table 2 .
Comparison of the proposed model with the related work