5.1 Dates Setup
20210318 Packages used in this chapter include lubridate (Spinu, Grolemund, and Wickham 2023), magrittr (Bache and Wickham 2022), and rattle (G. Williams 2022).
Packages are loaded into the currently running R session from your
local library directories on disk. Missing packages can be installed
using utils::install.packages() within R. On Ubuntu, for
example, R packages can also be installed using
$ wajig install r-cran-<pkgname>.
# Load required packages from local library into the R session. library(lubridate) # Tidy dates and time.
The rattle::weatherAUS dataset is loaded into the template
ds and further template variables are setup as
introduced by Graham J. Williams (2017). See
Chapter 8 for details.
<- "weatherAUS" dsname <- get(dsname) ds <- nrow(ds) nobs <- names(ds) vnames %<>% clean_names(numerals="right") ds names(vnames) <- names(ds) <- names(ds) vars <- "rain_tomorrow" target <- c(target, vars) %>% unique() %>% rev()vars
Bache, Stefan Milton, and Hadley Wickham. 2022. Magrittr: A Forward-Pipe Operator for r. https://CRAN.R-project.org/package=magrittr.
Spinu, Vitalie, Garrett Grolemund, and Hadley Wickham. 2023. Lubridate: Make Dealing with Dates a Little Easier. https://CRAN.R-project.org/package=lubridate.
Williams, Graham. 2022. Rattle: Graphical User Interface for Data Science in r. https://rattle.togaware.com/.
Williams, Graham J. 2017. The Essentials of Data Science: Knowledge Discovery Using r. The r Series. CRC Press.
Your donation will support ongoing availability and give you access to the PDF version of this book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2022 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0