This report summarizes the analysis of Germany’s daily electricity consumption, focusing on trends, seasonal patterns, and forecasting.
The data-set contains daily electricity consumption, wind, and solar production data from 2006 to 2018.
| Date | Consumption | Wind | Solar | Wind.Solar |
|---|---|---|---|---|
| 2006-01-01 | 1069.184 | NA | NA | NA |
| 2006-01-02 | 1380.521 | NA | NA | NA |
| 2006-01-03 | 1442.533 | NA | NA | NA |
| 2006-01-04 | 1457.217 | NA | NA | NA |
| 2006-01-05 | 1477.131 | NA | NA | NA |
| 2006-01-06 | 1403.427 | NA | NA | NA |
Summarize Data Frame to understand better way.
| Date | Consumption | Wind | Solar | Wind.Solar | |
|---|---|---|---|---|---|
| Min. :2006-01-01 | Min. : 842.4 | Min. : 5.757 | Min. : 1.968 | Min. : 21.48 | |
| 1st Qu.:2008-12-31 | 1st Qu.:1217.9 | 1st Qu.: 62.353 | 1st Qu.: 35.179 | 1st Qu.:172.19 | |
| Median :2012-01-01 | Median :1367.1 | Median :119.098 | Median : 86.407 | Median :240.99 | |
| Mean :2012-01-01 | Mean :1338.7 | Mean :164.814 | Mean : 89.259 | Mean :272.66 | |
| 3rd Qu.:2014-12-31 | 3rd Qu.:1457.8 | 3rd Qu.:217.900 | 3rd Qu.:135.071 | 3rd Qu.:338.99 | |
| Max. :2017-12-31 | Max. :1709.6 | Max. :826.278 | Max. :241.580 | Max. :851.56 | |
| NA | NA | NA’s :1463 | NA’s :2195 | NA’s :2196 |
## [1] "2006-01-01" "2006-01-02" "2006-01-03" "2006-01-04" "2006-01-05"
## [6] "2006-01-06"
## Date Consumption Wind Solar Wind.Solar year month day
## 1 2006-01-01 1069.184 NA NA NA 2006 1 1
## 2 2006-01-02 1380.521 NA NA NA 2006 1 2
## 3 2006-01-03 1442.533 NA NA NA 2006 1 3
## 4 2006-01-04 1457.217 NA NA NA 2006 1 4
## 5 2006-01-05 1477.131 NA NA NA 2006 1 5
## 6 2006-01-06 1403.427 NA NA NA 2006 1 6
The plot below shows the yearly average electricity consumption in Germany. goal : identify trends in electricity consumption over the year
## [1] "Year with minimum daily consumption: 2009 Value: 842.395"
## [1] "Year with maximum daily consumption: 2010 Value: 1709.568"
By calculating Correlation yealy between two parameter(consumption,year) show trends like in this we got Positive value that means by over the year cause increase consumption.
## [1] "Positive Correlation that means Positive trend"
The plot below shows the monthly average electricity consumption.
Similarly we see negative trend here that’s conclude over the month we see decreasing order in electricity consumption.
## [1] -0.07394412
## [1] "Correlation value is -ve that means -ve trend low corelation"
| weekends | Consumption |
|---|---|
| Wednesday | maximum consumption |
| Sunday | minimum consumption |
As we see the output is negative that conclude the trend is negative , over the days the consumption is become low
## [1] -0.02135832
We tested if electricity consumption differs significantly across years.
## Df Sum Sq Mean Sq F value Pr(>F)
## factor(year) 11 8303614 754874 29.43 <2e-16 ***
## Residuals 4371 112120696 25651
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
The p-value is less than 0.05, indicating significant differances in consumption across years.
We also tested if consumption differs across seasons.
## Df Sum Sq Mean Sq F value Pr(>F)
## season 3 15227607 5075869 211.3 <2e-16 ***
## Residuals 4379 105196703 24023
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
The p-value is less than 0.05, indicating significant differences in consumption across seasons.
The matrix below shows the correlation between consumption, wind, and solar production.
We fitted an ARIMA model to forecast future electricity consumption.
| ME | RMSE | MAE | MPE | MAPE | MASE | ACF1 | |
|---|---|---|---|---|---|---|---|
| Training set | -0.0354426 | 83.39549 | 59.83591 | -0.3915875 | 4.674948 | 0.4853672 | -0.0344969 |
We also fitted an ETS model for comparison.
| ME | RMSE | MAE | MPE | MAPE | MASE | ACF1 | |
|---|---|---|---|---|---|---|---|
| Training set | -0.0416266 | 57.8157 | 32.27235 | -0.1462378 | 2.586819 | 0.6242534 | 0.0860811 |
Electricity consumption in Germany shows clear yearly, monthly, and daily trends.
There are significant differences in consumption across years and seasons.
The ETS model provided a better fit for forecasting compared to ARIMA.