createDummyFeatures {mlr} | R Documentation |
Generate dummy variables for factor features.
Description
Replace all factor features with their dummy variables. Internally model.matrix is used. Non factor features will be left untouched and passed to the result.
Usage
createDummyFeatures(
obj,
target = character(0L),
method = "1-of-n",
cols = NULL
)
Arguments
obj |
(data.frame | Task) |
target |
( |
method |
(
Default is “1-of-n”. |
cols |
(character) |
Value
data.frame | Task. Same type as obj
.
See Also
Other eda_and_preprocess:
capLargeValues()
,
dropFeatures()
,
mergeSmallFactorLevels()
,
normalizeFeatures()
,
removeConstantFeatures()
,
summarizeColumns()
,
summarizeLevels()