R/check_data.R
check_data.Rd
Checks the Dataset and sets attributes on it for use in explore_data
check_data(dataset, covariates = NULL, outcome_var = NULL)
dataset |
|
---|---|
covariates |
|
outcome_var |
|
data.table with the following attributes: outcome_var (validated outcomes),
library(ggplot2) data(diamonds) diamond_frame <- check_data(diamonds, outcome_var=c("cut")) attr(diamond_frame, "categoricalVars")#> [1] "clarity" "color" "cut"#> [1] "carat" "depth" "price" "table" "x" "y" "z"#> [1] "cut"