## 3 Methodology
### Evaluation Metrics  
Table 1 shows a description of a confusion matrix. It is a numeric matrix where we can see the number of successes of the model for the different classes. The confusion matrix of Table 1 is for algorithms classifying data into two classes (binary classification): Positive and Negative. For constructing it, it is necessary to compute the following values:  
* Number of True Positives (_TPs_): the class assigned to the sample by the model is Positive and it is also the real class. * Number of False Negatives (_FNs_): the class assigned to the sample by the model is Negative, but the real class is Positive. * Number of False Positives (_FPs_): the class assigned to the sample by the model is Positive, but the real class is Negative. * Number of True Negatives (_TNs_): the class assigned to the sample by the model is Negative and it is also the real class. * Number of Total Samples (_Total_). From those metrics, we can also obtain different metrics to measure the model's performance. * _Accuracy_: Percentage of data correctly classified. \[Accuracy=\frac{TP+TN}{Total}\] (1)
* _Misclassification Rate_: Percentage of misclassified data. \[\textit{Misclassification Rate}=\frac{FP+FN}{Total}\] (2)
* _Precision_: The percentage of correct predictions obtained. \[Precision=\frac{TP}{TP+FP}\] (3)
* _Recall_: True positive rate, the percentage of data that manages to be classified from the positive class. \[Recall=\frac{TP}{TP+FN}\] (4)  
Precision and recall can be associated with the positive and negative classes. In our case, we will focus on reducing the number of false negatives since these would be cases of overweight or obesity that our model does not detect. In other words, we seek to obtain a high recall of the positive class. The GA selects the best set of features for prediction. A solution is represented by a binary chain (chromosome), with as many positions as features available in the curated dataset. Each of the positions (genes) in the chromosome applies to a feature. The value \begin{table}
\begin{tabular}{c c c} \hline \hline  & _Positive Prediction_ & _Negative Prediction_ \\ \hline _Positive Class_ & (TP) & (_FN_) \\ _Negative Class_ & (FP) & (_TN_) \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Example of confusion matrix structure for binary classification. Figure 1: Workflow diagram. of the gene will indicate if the feature is selected (1) or not (0) as the prediction variable. The initial population will be generated randomly. Due to the fact that we have a balanced dataset, to evaluate an individual (a model), we used a classical cross-validation scheme, with stratification [23]. Each model is trained using only the features expressed as \(1s\) in the individual genotype. The average accuracy rate of the 10 folds, \(F\), is used as fitness function:  
\[F=\frac{1}{10}\sum_{i=1}^{10}\text{Accuracy}_{i}\]  
where \(\text{Accuracy}_{i}\) is the accuracy obtained for each one of the cross-validation folds [24]. In this paper, we propose a variation of the _Stud GA_ method and we compare its performance with a traditional tournament implementation. The _Stud_ selection method works as follows. First, the four best individuals of the generation are selected, and form the _Stud candidates group_. Second, the two best individuals pass to the following iteration without crossover. Finally, the rest of the population is completed by applying the crossover operator to a pair formed by: (i) a member of the _Stud candidates group_ and (ii) another individual of the population in the event that the probability of crossover is met. For the tournament selection, we use a simple implementation with selection pressure of five [25]. As usual in the literature [26], we denote selective pressure to the size of the tournament pool. Adjusting this parameter allows us to find a trade-off between exploration and exploitation of the fitness landscape of the algorithm.