weather: Sample dataset of daily weather observations from Canberra...

weatherR Documentation

Sample dataset of daily weather observations from Canberra airport in Australia.

Description

One year of daily weather observations collected from the Canberra airport in Australia was obtained from the Australian Commonwealth Bureau of Meteorology and processed to create this sample dataset for illustrating data mining using R and Rattle.

Usage

weather_na.rm

Format

A data frame of 354 observations of 20 variables. One year of daily observations of weather variables at Canberra airport in Australia between November 1, 2007 and October 31, 2008.

  • Date, The date of observation (Date class).

  • MinTemp, The minimum temperature in degrees Celsius.

  • MaxTemp, The maximum temperature in degrees Celsius.

  • Rainfall, The amount of rainfall recorded for the day in mm.

  • Evaporation, The "Class A pan evaporation" (mm) in the 24 hours to 9am.

  • WindSpeed3pm, Wind speed (km/hr) averaged over 10 minutes prior to 3pm.

  • Humid9am, Relative humidity (percent) at 9am.

  • Humid3pm, Relative humidity (percent) at 3pm.

  • Pressure9am, Atmospheric pressure (hpa) reduced to mean sea level at 9am.

  • Pressure3pm, Atmospheric pressure (hpa) reduced to mean sea level at 3pm.

  • Cloud9am, Fraction of sky obscured by cloud at 9am. This is measured in "oktas", which are a unit of eighths. It records how many eighths of the sky are obscured by cloud. A 0 measure indicates completely clear sky whilst an 8 indicates that it is completely overcast.

  • Cloud3pm, Fraction of sky obscured by cloud (in "oktas": eighths) at 3pm. See Cloud9am for a description of the values.

  • Temp9am, Temperature (degrees C) at 9am.

  • Temp3pm, Temperature (degrees C) at 3pm.

  • RISK_MM, The amount of rain. A kind of measure of the "risk".

  • RainToday, Factor: "yes" if precipitation (mm) in the 24 hours to 9am exceeds 1mm, otherwise 0.

  • RainTomorrow, Factor: "yes" if it rained the following day, the target variable.

Copyright Commonwealth of Australia 2010, Bureau of Meteorology. Definitions adapted from http://www.bom.gov.au/climate/dwo/IDCJDW0000.shtml

Details

The data has been processed to provide a target variable RainTomorrow (whether there is rain on the following day - No/Yes) and a risk variable RISK_MM (how much rain recorded in millimeters). Various transformations were performed on the source data. The dataset is quite small and is useful only for repeatable demonstration of various data science operations.

This is a cleaned subset of rattle::weather.

Replicating this dataset:

require("rattle")
d <- rattle::weather[, c(1, 3:7, 9, 12:21, 23, 22, 24)]
d <- d[complete.cases(d), ] ## Remove ~12 row-wise incomplete rows
d <- as.data.frame(d)  ## Remove tibble dependency
weather_na.rm <- d
## save(weather_na.rm, file = "./data/weather_na.rm.rda")

Source

Bureau of Meteorology, Commonwealth of Australia http://www.bom.gov.au/climate/data/

rattle, R package. G. Williams, 2020. rattle: Graphical User Interface for Data Science in R https://CRAN.R-project.org/package=rattle

Examples

library(spinifex)
str(weather_na.rm)
dat  <- scale_sd(weather_na.rm[, 2:18])
clas <- weather_na.rm$RainTomorrow

bas <- basis_pca(dat)
mv  <- manip_var_of(bas)
mt  <- manual_tour(bas, mv)

ggt <- ggtour(mt, dat, angle = .2) +
  proto_default(aes_args = list(color = clas, shape = clas))

animate_plotly(ggt)


spinifex documentation built on May 29, 2024, 1:23 a.m.