8 min read

Building Energy Usage Exploratory Data Analysis


apartments
Apartments

View raw source for this post

Summary

Exploratory data analysis of building energy usage.

Table of Contents

Overview

The data set originally served as the basis for an article entitled “Data driven prediction models of energy use of appliances in a low-energy house.” [1] Since the publication of the article, the data set is available at the UCI Machine Learning Repository and can be found here. According to the website,

“the data set is time series measured at 10 minute intervals for 4.5 months. The house temperature and humidity conditions were monitored with a ZigBee wireless sensor network. Each wireless node transmitted the temperature and humidity conditions around 3.3 min. Then, the wireless data was averaged for 10 minutes periods. The energy data was logged every 10 minutes with m-bus energy meters. Weather from the nearest airport weather station (Chievres Airport, Belgium) was downloaded from a public data set from Reliable Prognosis (rp5.ru), and merged together with the experimental data sets using the date and time column. Two random variables have been included in the data set for testing the regression models and to filter out non predictive attributes (parameters). GitHub Repo.”

The data set was simplified to reduce the file size by grouping the measurements by the hour rather than the 10-minute interval. The resulting dataset contained 1/6 of the rows of the original. The interior rooms were averaged into a single inside measure for both temperature and relative humidity. This eliminated 16 columns.

Summary

Table

vars n mean sd median trimmed mad min max range skew kurtosis se
day 1 3290 NaN NA NA NaN NA Inf -Inf -Inf NA NA NA
appliances_avg 2 3290 97.78 81.21 63.33 79.73 27.18 28.33 608.33 580.00 2.39 6.31 1.42
lights_avg 3 3290 3.80 6.90 0.00 2.06 0.00 0.00 51.67 51.67 2.14 4.16 0.12
t_out_avg 4 3290 7.42 5.32 6.92 7.13 4.97 -4.96 25.93 30.89 0.54 0.36 0.09
press_mm_hg_avg 5 3290 755.52 7.40 756.10 755.86 7.46 729.38 772.26 42.88 -0.42 0.07 0.13
rh_out_avg 6 3290 79.74 14.83 83.67 81.39 13.84 25.25 100.00 74.75 -0.92 0.26 0.26
windspeed_avg 7 3290 4.04 2.43 3.58 3.78 2.35 0.42 13.00 12.58 0.86 0.25 0.04
visibility_avg 8 3290 38.33 11.21 40.00 37.56 9.27 1.00 66.00 65.00 0.44 0.42 0.20
tdewpoint_avg 9 3290 3.76 4.19 3.41 3.66 4.08 -6.47 15.25 21.73 0.24 -0.13 0.07
rv1_avg 10 3290 24.99 5.94 24.95 24.97 6.20 5.26 43.61 38.35 0.01 -0.22 0.10
t_in_avg 11 3290 19.38 2.15 19.05 19.23 1.99 14.71 25.68 10.97 0.61 0.03 0.04
rh_in_avg 12 3290 42.71 5.95 42.43 42.67 6.51 27.67 57.82 30.15 0.07 -0.64 0.10

Violin Plot

Outcome Variables

Energy Use by Hour

Energy Use by Hour and Day of Week

Calendar Heatmap

Radar Plot

Predictor Variables

Weather - Exterior

Building - Interior

Correlogram

Conclusion

Lights and appliances are used differently within an interior space, although both are low during the hours of 10:00 p.m. to 6:00 a.m. Appliance use reaches its maximal levels around traditional supper/dinner time. Light usage is linked to sunset and sunrise. Seasonal variation is present as well. Energy usage declines as the days lengthen and the temperatures warm.

References

[1]
L. M. Candanedo, V. Feldheim, and D. Deramaix, “Data driven prediction models of energy use of appliances in a low-energy house,” Energy and Buildings, vol. 140, pp. 81–97, Apr. 2017, doi: 10.1016/j.enbuild.2017.01.083. [Online]. Available: https://www.sciencedirect.com/science/article/pii/S0378778816308970. [Accessed: 13-Jan-2023]
[2]
R Core Team, R: A language and environment for statistical computing. Vienna, Austria: R Foundation for Statistical Computing, 2022 [Online]. Available: https://www.R-project.org/
[3]
Y. Xie, C. Dervieux, and A. Presmanes Hill, Blogdown: Create blogs and websites with r markdown. 2022 [Online]. Available: https://CRAN.R-project.org/package=blogdown
[4]
R. Ihaka et al., Colorspace: A toolbox for manipulating and assessing colors and palettes. 2022 [Online]. Available: https://CRAN.R-project.org/package=colorspace
[5]
M. Nakazawa, Fmsb: Functions for medical statistics book with some demographic data. 2023 [Online]. Available: https://minato.sip21c.org/msb/
[6]
B. Schloerke et al., GGally: Extension to ggplot2. 2021 [Online]. Available: https://CRAN.R-project.org/package=GGally
[7]
D. Attali and C. Baker, ggExtra: Add marginal histograms to ggplot2, and more ggplot2 enhancements. 2022 [Online]. Available: https://github.com/daattali/ggExtra
[8]
H. Zhu, kableExtra: Construct complex table with kable and pipe syntax. 2021 [Online]. Available: https://CRAN.R-project.org/package=kableExtra
[9]
V. Spinu, G. Grolemund, and H. Wickham, Lubridate: Make dealing with dates a little easier. 2022 [Online]. Available: https://CRAN.R-project.org/package=lubridate
[10]
T. L. Pedersen, Patchwork: The composer of plots. 2022 [Online]. Available: https://CRAN.R-project.org/package=patchwork
[11]
W. Revelle, Psych: Procedures for psychological, psychometric, and personality research. 2022 [Online]. Available: https://personality-project.org/r/psych/ https://personality-project.org/r/psych-manual.pdf
[12]
H. Wickham, Stringr: Simple, consistent wrappers for common string operations. 2022 [Online]. Available: https://CRAN.R-project.org/package=stringr
[13]
S. Garnier, Viridis: Colorblind-friendly color maps for r. 2021 [Online]. Available: https://CRAN.R-project.org/package=viridis

Disclaimer

The views, analysis and conclusions presented within this paper represent the author’s alone and not of any other person, organization or government entity. While I have made every reasonable effort to ensure that the information in this article was correct, it will nonetheless contain errors, inaccuracies and inconsistencies. It is a working paper subject to revision without notice as additional information becomes available. Any liability is disclaimed as to any party for any loss, damage, or disruption caused by errors or omissions, whether such errors or omissions result from negligence, accident, or any other cause. The author(s) received no financial support for the research, authorship, and/or publication of this article.

Reproducibility

─ Session info ───────────────────────────────────────────────────────────────────────────────────────────────────────
 setting  value
 version  R version 4.2.2 (2022-10-31)
 os       macOS Big Sur ... 10.16
 system   x86_64, darwin17.0
 ui       X11
 language (EN)
 collate  en_US.UTF-8
 ctype    en_US.UTF-8
 tz       America/New_York
 date     2023-01-13
 pandoc   2.19.2 @ /Applications/RStudio.app/Contents/Resources/app/quarto/bin/tools/ (via rmarkdown)

─ Packages ───────────────────────────────────────────────────────────────────────────────────────────────────────────
 package      * version date (UTC) lib source
 assertthat     0.2.1   2019-03-21 [1] CRAN (R 4.2.0)
 blogdown     * 1.16    2022-12-13 [1] CRAN (R 4.2.0)
 bookdown       0.31    2022-12-13 [1] CRAN (R 4.2.0)
 bslib          0.4.2   2022-12-16 [1] CRAN (R 4.2.0)
 cachem         1.0.6   2021-08-19 [1] CRAN (R 4.2.0)
 callr          3.7.3   2022-11-02 [1] CRAN (R 4.2.0)
 cli            3.6.0   2023-01-09 [1] CRAN (R 4.2.0)
 codetools      0.2-18  2020-11-04 [1] CRAN (R 4.2.2)
 colorspace   * 2.0-3   2022-02-21 [1] CRAN (R 4.2.0)
 crayon         1.5.2   2022-09-29 [1] CRAN (R 4.2.0)
 DBI            1.1.3   2022-06-18 [1] CRAN (R 4.2.0)
 devtools     * 2.4.5   2022-10-11 [1] CRAN (R 4.2.0)
 digest         0.6.31  2022-12-11 [1] CRAN (R 4.2.2)
 dplyr        * 1.0.10  2022-09-01 [1] CRAN (R 4.2.0)
 ellipsis       0.3.2   2021-04-29 [1] CRAN (R 4.2.0)
 evaluate       0.18    2022-11-07 [1] CRAN (R 4.2.0)
 fansi          1.0.3   2022-03-24 [1] CRAN (R 4.2.0)
 farver         2.1.1   2022-07-06 [1] CRAN (R 4.2.0)
 fastmap        1.1.0   2021-01-25 [1] CRAN (R 4.2.0)
 fmsb         * 0.7.5   2023-01-05 [1] CRAN (R 4.2.0)
 fs             1.5.2   2021-12-08 [1] CRAN (R 4.2.0)
 generics       0.1.3   2022-07-05 [1] CRAN (R 4.2.0)
 GGally       * 2.1.2   2021-06-21 [1] CRAN (R 4.2.0)
 ggExtra      * 0.10.0  2022-03-23 [1] CRAN (R 4.2.0)
 ggplot2      * 3.4.0   2022-11-04 [1] CRAN (R 4.2.0)
 ggthemes     * 4.2.4   2021-01-20 [1] CRAN (R 4.2.0)
 glue           1.6.2   2022-02-24 [1] CRAN (R 4.2.0)
 gridExtra      2.3     2017-09-09 [1] CRAN (R 4.2.0)
 gtable         0.3.1   2022-09-01 [1] CRAN (R 4.2.0)
 highr          0.9     2021-04-16 [1] CRAN (R 4.2.0)
 htmltools      0.5.4   2022-12-07 [1] CRAN (R 4.2.0)
 htmlwidgets    1.6.0   2022-12-15 [1] CRAN (R 4.2.0)
 httpuv         1.6.8   2023-01-12 [1] CRAN (R 4.2.2)
 httr           1.4.4   2022-08-17 [1] CRAN (R 4.2.0)
 jquerylib      0.1.4   2021-04-26 [1] CRAN (R 4.2.0)
 jsonlite       1.8.4   2022-12-06 [1] CRAN (R 4.2.0)
 kableExtra   * 1.3.4   2021-02-20 [1] CRAN (R 4.2.0)
 knitr          1.41    2022-11-18 [1] CRAN (R 4.2.0)
 labeling       0.4.2   2020-10-20 [1] CRAN (R 4.2.0)
 later          1.3.0   2021-08-18 [1] CRAN (R 4.2.0)
 lattice        0.20-45 2021-09-22 [1] CRAN (R 4.2.2)
 lifecycle      1.0.3   2022-10-07 [1] CRAN (R 4.2.0)
 lubridate    * 1.9.0   2022-11-06 [1] CRAN (R 4.2.0)
 magrittr       2.0.3   2022-03-30 [1] CRAN (R 4.2.0)
 Matrix         1.5-1   2022-09-13 [1] CRAN (R 4.2.2)
 memoise        2.0.1   2021-11-26 [1] CRAN (R 4.2.0)
 mgcv           1.8-41  2022-10-21 [1] CRAN (R 4.2.2)
 mime           0.12    2021-09-28 [1] CRAN (R 4.2.0)
 miniUI         0.1.1.1 2018-05-18 [1] CRAN (R 4.2.2)
 mnormt         2.1.1   2022-09-26 [1] CRAN (R 4.2.0)
 munsell        0.5.0   2018-06-12 [1] CRAN (R 4.2.0)
 nlme           3.1-160 2022-10-10 [1] CRAN (R 4.2.2)
 patchwork    * 1.1.2   2022-08-19 [1] CRAN (R 4.2.0)
 pillar         1.8.1   2022-08-19 [1] CRAN (R 4.2.0)
 pkgbuild       1.4.0   2022-11-27 [1] CRAN (R 4.2.0)
 pkgconfig      2.0.3   2019-09-22 [1] CRAN (R 4.2.0)
 pkgload        1.3.2   2022-11-16 [1] CRAN (R 4.2.0)
 plyr           1.8.8   2022-11-11 [1] CRAN (R 4.2.0)
 prettyunits    1.1.1   2020-01-24 [1] CRAN (R 4.2.0)
 processx       3.8.0   2022-10-26 [1] CRAN (R 4.2.0)
 profvis        0.3.7   2020-11-02 [1] CRAN (R 4.2.0)
 promises       1.2.0.1 2021-02-11 [1] CRAN (R 4.2.0)
 ps             1.7.2   2022-10-26 [1] CRAN (R 4.2.0)
 psych        * 2.2.9   2022-09-29 [1] CRAN (R 4.2.0)
 purrr          0.3.5   2022-10-06 [1] CRAN (R 4.2.0)
 R6             2.5.1   2021-08-19 [1] CRAN (R 4.2.0)
 RColorBrewer   1.1-3   2022-04-03 [1] CRAN (R 4.2.0)
 Rcpp           1.0.9   2022-07-08 [1] CRAN (R 4.2.0)
 remotes        2.4.2   2021-11-30 [1] CRAN (R 4.2.0)
 reshape        0.8.9   2022-04-12 [1] CRAN (R 4.2.0)
 rlang          1.0.6   2022-09-24 [1] CRAN (R 4.2.0)
 rmarkdown      2.18    2022-11-09 [1] CRAN (R 4.2.0)
 rstudioapi     0.14    2022-08-22 [1] CRAN (R 4.2.0)
 rvest          1.0.3   2022-08-19 [1] CRAN (R 4.2.0)
 sass           0.4.4   2022-11-24 [1] CRAN (R 4.2.0)
 scales         1.2.1   2022-08-20 [1] CRAN (R 4.2.0)
 sessioninfo    1.2.2   2021-12-06 [1] CRAN (R 4.2.0)
 shiny          1.7.4   2022-12-15 [1] CRAN (R 4.2.2)
 stringi        1.7.12  2023-01-11 [1] CRAN (R 4.2.2)
 stringr      * 1.5.0   2022-12-02 [1] CRAN (R 4.2.0)
 svglite        2.1.0   2022-02-03 [1] CRAN (R 4.2.0)
 systemfonts    1.0.4   2022-02-11 [1] CRAN (R 4.2.0)
 tibble         3.1.8   2022-07-22 [1] CRAN (R 4.2.0)
 tidyr        * 1.2.1   2022-09-08 [1] CRAN (R 4.2.0)
 tidyselect     1.2.0   2022-10-10 [1] CRAN (R 4.2.0)
 timechange   * 0.2.0   2023-01-11 [1] CRAN (R 4.2.2)
 urlchecker     1.0.1   2021-11-30 [1] CRAN (R 4.2.0)
 usethis      * 2.1.6   2022-05-25 [1] CRAN (R 4.2.0)
 utf8           1.2.2   2021-07-24 [1] CRAN (R 4.2.0)
 vctrs          0.5.1   2022-11-16 [1] CRAN (R 4.2.0)
 viridis      * 0.6.2   2021-10-13 [1] CRAN (R 4.2.0)
 viridisLite  * 0.4.1   2022-08-22 [1] CRAN (R 4.2.0)
 webshot        0.5.4   2022-09-26 [1] CRAN (R 4.2.0)
 withr          2.5.0   2022-03-03 [1] CRAN (R 4.2.0)
 xfun           0.35    2022-11-16 [1] CRAN (R 4.2.0)
 xml2           1.3.3   2021-11-30 [1] CRAN (R 4.2.0)
 xtable         1.8-4   2019-04-21 [1] CRAN (R 4.2.0)
 yaml           2.3.6   2022-10-18 [1] CRAN (R 4.2.0)

 [1] /Library/Frameworks/R.framework/Versions/4.2/Resources/library

──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────