# Short Term Electric Load Forecasting Based on Data Transformation and Statistical Machine Learning
## 2 Proposed Methodology
### Time Interval Selection  
After examining stationarity, the next step would be to partition the dataset and transform it into an image-like matrix. For this step a deep statistical analysis is necessary, in order to determine the autocorrelation coefficients of the given datasets by applying the Auto-Correlation Function (ACF) test. The majority of multi-step forecasting strategies introduce errors, which are directly dependent on the forecasting horizon; the longer the forecasting horizon, the higher the errors. Consequently, reduced precision is inevitable as the horizon grows. To alleviate the absence of data stationarity, a novel technique is proposed that leads to a performance closer to uni-step forecasting methods. Specifically, we introduce a technique that manages to shorten the forecasting horizon so as to mimic a uni-step forecasting method. This is achieved by choosing the inputs of our model in an alternative way, which is explained below. Despite that the method of determining the inputs of NN for STLF still remains an open question. The most common technique is to use as input the immediately preceded value. So, if we want to predict \(n\) we will have as input the \(n-1\) value. This achieves great results in uni-step forecasting but for multi-step it introduces some errors, since the forecasted errors are accumulated and the final predicted value will not be accurate. In our case, the inputs are determined based on the experience or an-priori knowledge about the behavior of the system. A rather intuitive guess in load forecasting is that there must be instants in the past homologous to the current period, either during the same period on the \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Dataset** & **Trento** & **Household** & **Office** \\ \hline Mean 1 & 44.58 & 235.73 & 1.25 \\ Mean 2 & 61.43 & 215.45 & 1.15 \\ STD 1 & 18.97 & 298.70 & 1.30 \\ STD 2 & 17.14 & 218.62 & 1.07 \\ Stationary & NO & NO & YES \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Stationarity analysis results. \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Dataset** & \(p\)**-Value (ADF Test)** & **ADF** & **Stationary** \\ \hline Trento & 0.01 & \(-\)3.40 & YES \\ Household & \(\ll\)0.01 & \(-\)18.4 & YES \\ \hline \hline \end{tabular}
\end{table} 
Table 2: ADF Test results. previous day (24 h ago) or during the same period on the previous week, or previous two weeks, and so on. In this paper, the inputs for the neural networks are determined after examining the ACF; the assumption regarding homologous instants is analyzed in the second part of our proposed methodology. Based on this analysis it was derived that the most recent 24-h data exhibit the highest correlation with the forecasts and as such they form the basic input of the proposed methodology. In this way, the day ahead forecast problem is transformed into a uni-step problem. The first part of the analysis deals with the development of the auto-correlation plot of observations starting at time t and for two days duration. Figures 2-4 present the correlation analysis and auto-correlation plots for Trento, household and office datasets. The vertical axis shows the ACF value, which ranges from \(-1\) to \(1\). The horizontal axis of the plot shows the size of the lag between the elements of the time series. For instance, the autocorrelation with lag 4 is the correlation between the time series elements and the corresponding elements observed four periods earlier. Figure 3: Autocorrelation plot for the single household data. The vertical axis shows the ACF value. The horizontal axis of the plot shows the size of the lag between the elements of the time series. Figure 2: Autocorrelation plot for Trento data. The vertical axis shows the ACF value. The horizontal axis of the plot shows the size of the lag between the elements of the time series.