Analisis Prediksi Harga Beras Berbasis Kualitas Menggunakan Algoritma K-Nearest Neighbord

Penulis

DOI:

https://doi.org/10.36982/jiig.v15i3.4810

Abstrak

Rice is an important element in improving national food security. There are several factors that affect the price of rice, including uncertain production. This study aims to predict the price of rice in the city of Pagar Alam using the K-Nearest Neighbor (K-NN) algorithm. The data used is rice price data from 2019 to 2023 obtained from the Pagar Alam City Trade Office. The resulting classification model is evaluated for its performance using various indicators such as accuracy, precision, and recall. The research process begins with a business understanding to identify factors that affect rice prices. Furthermore, data understanding was carried out on 240 rice data samples including the attributes of year, month, production, price, and type of rice. This data is processed using the K-NN method, which involves calculating the Euclidean distance between training data and testing data and testing accuracy through split data that the K-Nearest Neighbor method is effective in predicting rice prices with an accuracy of 95%, which shows that this model has a good ability to classify rice prices accurately. This research has been successful and can help the Trade Service in making decisions regarding rice prices and be a reference for similar research in the future.

Diterbitkan

2024-11-29

Cara Mengutip

Setiadi, D., & Efan. (2024). Analisis Prediksi Harga Beras Berbasis Kualitas Menggunakan Algoritma K-Nearest Neighbord. Jurnal Ilmiah Informatika Global, 15(3), 106–115. https://doi.org/10.36982/jiig.v15i3.4810