preprocess.NAs: Handling missing values in a df

Description Usage Arguments Value Author(s) Examples

Description

Replaces numeric and factor columns NAs with user defined values

Usage

1
preprocess.NAs(df, numeric.v, factor.v = "None")

Arguments

df

A data frame. numeric and factor columns will be considered

numeric.v

Numeric value, NAs will be replaced with. Default is 0.

factor.v

Factor value, NAs will be replaced with. Default is None.

Value

This function returns the initial data.frame with NAs replaced

Author(s)

Eva Szin Takacs, szin.takacs.eva@gmail.com

Examples

1
preprocess.NAs(weather, 0, "None")

szintakacseva/mlhelper documentation built on June 4, 2019, 6:22 p.m.