Journal of Mathematics, Computation and Statistics (JMATHCOS)
Vol. 8 No. 2 (2025): Volume 08 Nomor 02 (Oktober 2025)

Implementation of Random Forest Algorithm for Shallot Price Forecasting in Makassar City

Hardianti Hafid (Unknown)
Arwini Arisandi (Unknown)
Reski Wahyu Yanti (Unknown)



Article Info

Publish Date
11 Sep 2025

Abstract

This study aims to implement the Random Forest algorithm for forecasting shallot prices in Makassar City using monthly historical data from January 2018 to December 2024, obtained from the Statistics Indonesia (Badan Pusat Statistik) of South Sulawesi Province. The analysis begins with identifying significant lags through the Partial Autocorrelation Function (PACF) plot, resulting in seven input variable schemes. Each scheme was tested using training and testing datasets. Model performance was evaluated using the Mean Absolute Percentage Error (MAPE). The results show that Scheme 1 (Lag 1) achieved the best performance with a MAPE value of 13.08%, which falls into the “good” category. Price forecasts for January–December 2025 using the best scheme indicate a price range of IDR 23,200 – 24,300 per kilogram, with peak prices in March, July, and November, and the lowest prices in April, August, and December. Although the model successfully captures historical price patterns, real-world fluctuations driven by seasonal factors, supply disruptions, and distribution costs may cause prediction deviations. This study recommends integrating exogenous variables and real-time data to improve forecasting accuracy and support local food price stabilization policies.

Copyrights © 2025






Journal Info

Abbrev

JMATHCOS

Publisher

Subject

Mathematics

Description

Fokus yang didasarkan tidak hanya untuk penelitian dan juga teori-teori pengetahuan yang tidak menerbitkan plagiarism. Ruang lingkup jurnal ini adalah teori matematika, matematika terapan, program perhitungan, perhitungan matematika, statistik, dan statistik ...