Active Power Demand Forecasting for an Electric Power System Using Machine Learning Algorithms for Medium-Term Expansion Planning
Robinson Reinoso-Acosta, Carlos Barrera-SingañaThis article forecasts electricity demand over two-month, one-year, and two-year horizons using 20 years of open-access data from the COES system operator. The proposed approach applies machine learning (ML) algorithms with exogenous variables and optimized LGBMRegressor hyperparameters to reduce forecasting error. Its performance is compared with mathematical statistical models (MSMs), including SARIMAX, ARIMA, and ARIMA with cross-validation. The MSM-based approaches produced lower performance metrics than the ML-based techniques and required longer computational execution times. The implementation was carried out in Google Colab Pro using Python 3.12 and libraries such as skforecast, taking advantage of the available high RAM capacity to reduce the computational time of the two forecasting techniques analyzed. For the two-month forecasting horizon, the lowest mean absolute error (MAE) was achieved with the LGBMRegressor algorithm including exogenous variables and optimized hyperparameters, with a value of 98.69 MW, whereas ARIMA with cross-validation yielded an error of 207.93 MW. These results indicate that the use of ML algorithms for electricity demand forecasting reduces forecasting errors and requires less computational execution time. Therefore, only ML was used for the one-year and two-year forecasting horizons. Based on this result, a one-year forecast was obtained with the LGBMRegressor algorithm, yielding an MAE of 111.77 MW, while the two-year forecast produced an MAE of 96.344 MW. This work incorporated socioeconomic exogenous variables, such as quarterly GDP, population, and access to electricity, which improved the medium-term forecasting model. The resulting forecasts may be useful for both the operation and planning of the electric power system (EPS).