Accurate prediction of energy consumption patterns is vital for attaining sustainability and efficient economic planning. In the USA energy consumption trends have evolved substantially because of factors such as population growth, technological advancements, and shifts in consumption behaviors. The prime objective of this research project was to develop and evaluate machine learning algorithms with accuracy in predicting trends in America's consumption of energy. By employing complex methodologies such as neural networks, regression analysis, and ensemble approaches, this work aims to enhance the accuracy of forecasts in terms of demand for energy in residential, commercial, and industrial sectors. The U.S. consumption datasets covered a wide variety of information representing the consumption of electricity, use of fuel, and integration of renewable sources in residential, commercial, and transportation sectors. Most datasets used for analysis are taken from the U.S. Energy Information Administration (EIA) and the Department of Energy (DOE), offering in-depth statistics about production, consumption trends, and price trends. With our dataset consisting of continuous values for consumption of energy and many predictor factors, we compared a variety of machine algorithms, encompassing XG-Boost, Logistic Regression, and Random Forest. The implemented code compared three algorithms – Logistic Regression, Random Forest, and XG-Boost – in terms of performance via calculation and visualization of key evaluation metrics. It devised a function calculate-metrics to calculate accuracy, precision, recall, and F1-score for a prediction of each model over a test set. Retrospectively, comparing accuracy values, one can observe that Logistic Regression got a high score, with Random Forest following closely, and XG-Boost following a little behind them. Overall, through strategic plots, the comparative strengths and weaknesses of all three algorithms were seen, proving that Logistic Regression was the most reliable algorithm for predicting values in a dataset. Utility companies can benefit a lot through machine learning (ML)-based prediction in terms of distribution efficiency and overall operational efficiency. With ML algorithms, utility companies can utilize humungous volumes of consumption in the past to make future demand predictions with high accuracy.
Read full abstract