get_caret_dummyvars_df | R Documentation |
Get dummyvars dataframe (i.e. design matrix)
get_caret_dummyvars_df(features, full_rank = FALSE, progbar = NULL)
features |
dataframe of features for machine learning |
full_rank |
whether matrix should be full rank or not (see 'caret::dummyVars) |
progbar |
optional progress bar (default: |
design matrix
Zena Lapp, zenalapp@umich.edu
## Not run:
df <- data.frame(
outcome = c("normal", "normal", "cancer"),
var1 = 1:3,
var2 = c("a", "b", "c"),
var3 = c("no", "yes", "no"),
var4 = c(0, 1, 0)
)
get_caret_dummyvars_df(df, TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.