Optimization of cross-validation testing on the decision tree and k-nearest neighbor in classifying election data - Desilia Selvida; Purwa Hasan Putra (Institute of Computer Science (IOCS), 2023)
General elections are the process of choosing someone who represents the people to occupy a government seat. Polemics regarding the postponement of the 2024 General Elections are widely discussed by Indonesian people. However, the fact is that the position of the government (executive) is currently the majority. This condition is caused by the support of a strong party coalition in the legislature (parliament) in a presidential system. This problem can be solved by data mining. Data mining is one way that can be used to predict and detect a case, including predicting the winning party. There are various kinds of algorithms. The results of the study are positive value predictions (class precision), namely 94.88% with 19 data suitability and 352 data discrepancies, for negative value predictions, namely 60.42% with 29 data suitability and 19 data discrepancies. Meanwhile, the true negative class recall was 94.88% and the true positive was 60.42%. The results of the accuracy of testing with a decision tree is 90.92%. While the results of the K-Nearest Neighbor optimization, it is known that the prediction of positive value (class precision) is 93.98% with 23 data suitability and 352 data discrepancy, for negative prediction value is 67.57% with 25 data suitability and 12 data discrepancy. While the true negative class recall was 96.77% and true positive was 52.08%. The results of the accuracy of testing with a decision tree is 91.65%.