R/ml_pipeline.R
morie_ml_impute.Rd
Mean/median/constant imputation of a numeric vector
morie_ml_impute(x, method = c("mean", "median", "constant"), value = 0)
Numeric vector.
One of "mean", "median", "constant".
Fill value when method = "constant".
method = "constant"
Imputed numeric vector.
morie_ml_impute(c(1, NA, 3), "mean") #> [1] 1 2 3