## 4 Analysis and Results
### The ICAFE Study Case  
The present section reports the results of the HMP-Coffee model for profitability variable (classes: **Favorable**, **Average**, and **Unfavorable**). We evaluated the HMP-Coffee model through a dataset provided by ICAFE [30]. We used the ICAFE dataset since according to ICO, the coffee economic structure is similar in Costa Rica and Colombia. For instance, in 2017, the coffee production cost in Costa Rica was 1956.36 [USD/ha], while in Colombia, 1874.85 [USD/ha]. Besides, in Costa Rica and Colombia, around 90% of coffee activity corresponds to smallholders [42]. The dataset comprises 405 instances with 17 attributes (15 concerning production cost, one related to the international market, and another to the production volume). ICAFE dataset is available at the GitHub repository [43]. We evaluated the performance of the HMP-Coffee model regarding the metrics associated with the confusion matrix. The corresponding results are shown in Table 6. The key diagonal (i.e., green cells) shows the correctly classified cases, whereas the other cells indicate the number of misclassifications. Class 1 has 362 instances: 31 were misclassified as Class 2 and 331 were correctly classified. Class 2 has 27 classified successfully without any misclassification. Class 3 has 15 samples: 2 cases were misclassified as class 2 and 13 were correctly classified. Overall, the HMP-Coffee model achieved an accuracy equal to 81.72%. Overall accuracy is often insufficient evidence to determine the robustness of an estimation model such as HMP-Coffee [44]. Therefore, we considered three additional metrics: Precision, Recall, and F1-score [45]. These metrics were computed using the multi-class confusion matrix from true positives (TP), false positives (FP), false negatives (FN), and true negatives (TN) rates; where TP, FP, FN, and TN vary by class. For instance, for the **Average** class, TP corresponds to the profitability classified as **Average** by the HMP-Coffee model and the ICAFE dataset. FP corresponds to the profitability identified by the HMP-Coffee model as **Average**, but in the ICAFE dataset is **Favorable** or **Unfavorable**. TN corresponds to profitability not classified as **Average** by the HMP-Coffee model. However, \begin{table}
\begin{tabular}{c c c c c} \hline \hline  & **Predicted** & **Class 1:** & **Class 2:** & **Class 3:** \\
**Real** & & **Favorable** & **Average** & **Unfavorable** \\ \hline Class 1: **Favorable** & 331 & 31 & 0 \\ \hline Class 2: **Average** & 0 & 27 & 0 \\ \hline Class 3: **Unfavorable** & 0 & 2 & 13 \\ \hline \hline \end{tabular}
\end{table} 
Table 6: Confusion matrix for the HMP-Coffee model. The Predicted columns correspond to the estimated profitability (Favorable, Average, and Unfavorable). Real rows columns correspond to the profitability of the ICAFE test dataset (Favorable, Average, and Unfavorable). they are **Average** in the ICAFE dataset. FN corresponds to the profitability not classified as Average by the HMP-Coffee, but in the ICAFE dataset is **Average**. For each class, we computed Precision, Recall, and F1-score individually. Table 7 presents the Precision, Recall, and F1-score achieved by the HMP-Coffee model for the **Favorable**, **Average**, and **Unfavorable** classes. HMP-Coffee classified with higher precision the **Favorable** and **Unfavorable** (0.99 and 0.98, respectively) classes than the **Average** class (0.450). HMP-Coffee classifies better extreme qualitative scales than the intermediate ones. In particular, HPM-Coffee suffers from FP when identifying the **Average** class. The detected FP problem occurs due to the use of scales in HMP-Coffee. For example, when the input values of \"Price of workforce\" are _10 and 19.9 dollars_ on a scale where **Cheap** ranges between _0-9.9_ dollars, _Average_ between _10-19.9 dollars_, and **Expensive**_higher than 20 dollars_, they are classified as _Average_; however, its closeness to the limit has a clear implication in the model's precision.