Description Usage Arguments Details Value Examples
bin_manual
cuts numeric, variables according to the mapping specified
by the user. This is a standard step in feature engineering or data
transformation for scorecard modelling.
1 | bin_manual(.data, bad, ..., check = FALSE)
|
.data |
A tibble or data.frame |
bad |
A variable name indicating which rows are bad borrowers |
... |
Named lists separated by commas containing mappings of variables
to a transformation. Cuts for each variable are separated by |
check |
A logical, if TRUE, |
Similar to the dplyr mutate
, the function takes a named list of lists,
separated by commas, with the variable name on the left side, and the
transformation on the right side. bin_manual
uses the c_l
and
c_r
functions to close where the values of a variable will be cut and
transformed into categories.
A tibble or data.frame with the variables transformed into character vectors.
1 2 3 4 5 | bin_manual(german, bad, age = c_l(40, 55))
bin_manual(german,
bad,
duration = c_r(15, 32),
check = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.