Data Science Desktop Survival Guide
by Graham Williams |
|||||
Variables and Model Target |
Reviewing the variables we will note the different roles each of the variables play. Again we make use of the template in identifying variable roles. Notice the choice to place the target variable at the end of the variable list which is common practice. Loading the dataset into rattle will then automatically identify this variable as the target variable. Reverse the list to generate a stats::formula().
# Note the available variables.
vars <- names(ds) %T>% print()
# Note the target variable.
target <- "rain_tomorrow" # Place the target variable at the beginning of the vars. vars <- c(target, vars) %>% unique() %>% rev() %T>% print()
|