## 3 Results
### Classification of Solid Waste with MNT Sensor Using Machine Learning Algorithms  
Among the various machine learning algorithms available, Random Forest was selected for the classification process using the MNT sensor due to its robustness and ability to handle highly variable data. Its ensemble learning approach, combining multiple decision trees, minimizes the risk of overfitting, ensuring stable and accurate predictions even in noisy environments. Furthermore, Random Forest allows the interpretation of feature importance, such as capacitance, facilitating the identification of patterns relevant to waste classification. While notable differences in capacitance exist between organic and recyclable waste, Random Forest ensures robust and automated classification in cases with smaller dielectric variations or in complex environments with significant data noise. Compared to more advanced algorithms like Support Vector Machines (SVM) or neural networks, Random Forest achieves an optimal balance between accuracy and computational efficiency, making it particularly suitable for resource-constrained deployments. The training, testing, and validation phases were carried out using the dataset collected during sampling campaigns with the MNT sensor, consisting of 100 records with capacitance (pF) as a feature distributed into two classes: reusable waste (Class 0) and organic waste (Class 1). The data analysis processes were implemented using Python 3.6.3 libraries such as sklearn, matplotlib, pandas, numpy, and scipy, through the Google Colab platform. For the Random Forest algorithm configuration process, the following parameters were established:  
* Number of trees (n_estimators): 100 trees. This value is commonly used as a standard in practical scenarios, and as a recommendation in default configurations of the Scikit-learn library, establishing a balance point between performance and computing time. * Split criterion: Gini. Used to evaluate the purity of the partitions in each node of the tree. * Maximum depth (max_depth): No limit. Allowing full growth of the trees and ensuring the capture of complex patterns in the data. * Minimum leaf sample size (min_samples_leaf): In order to avoid overfitting by reducing variability in the final predictions. To ensure transparency and minimize experimental errors, the following additional techniques were applied:  
* Data normalization: The RobustScaler technique from the sklearn library was used to adjust the capacitance values and mitigate the influence of outliers on the model. * Data splitting: The dataset was split into 80% for training and 20% for testing using the train_test_split function, using a random seed to ensure reproducibility. Figure 10 presents the confusion matrix obtained for the Random Forests model, in which there were no false positive or false negative records, correctly classifying the 75 records belonging to Class 0 (reusable waste) and the 25 records of Class 1 (organic waste), demonstrating adequate levels of precision and reliability during the classification process according to the reading made by the sensor. In turn, performance metrics such as accuracy, precision, recall, and F1-score were calculated for the Random Forests model, obtaining a perfect value of 1.0 in all cases. This result reflects optimal performance. Additionally, the absence of overfitting was validated by the consistency of all metrics, thus avoiding relying solely on the accuracy metric, which can be misleading under bias conditions. Figure 11 presents the graphic validation of the proposed classification model, in which the decision limits used to separate the waste classes can be clearly seen. In turn, the reference line observed horizontally reflects consistent thresholds for the capacitance values corresponding to each type of waste.