Simple mean imputation of missing values

impute_mean(data)

Arguments

data

A matrix or data frame object. It should have variables as columns and observations as rows.

Value

A list object with positions of missing values (positions), imputed values by observed mean (imp_values) and new data with imputed values (new_data).