mutate_dicotomize | R Documentation |
Create a dicotomized x column based on first rpart split
mutate_dicotomize(.data, x, y)
.data |
A data frame, data frame extension (e.g. a tibble), or a lazy data frame (e.g. from dbplyr or dtplyr) |
x |
name of predictor to dicotomize |
y |
name of response to base dicotomization on |
.data with a new factor representing the optimal split
rpart
mutate_dicotomize(iris, Sepal.Length, Sepal.Width)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.