ce.mimp {dprep} | R Documentation |
A function that detects location of missing values by class, then imputes the missing values that occur in the features, using mean or median imputation, as specified by the user. If the feature is nominal then a mode imputation is done.
ce.mimp(w.cl, method = c("mean", "median"), atr, nomatr = 0)
w.cl |
dataset with missing values. |
method |
either "mean" or "median" |
atr |
list of relevant features |
nomatr |
list of nominal features, imputation is done using mode |
w.cl |
the original matrix with values imputed |
A description of all the imputations carried out may be stored in a report that is later saved to the current workspace. To produce the report, lines at the end of the code must be uncommented. The report objects name starts with Imput.rep.
Caroline Rodriguez and Edgar Acuna
Acuna, E. and Rodriguez, C. (2004). The treatment of missing values and its effect in the classifier accuracy. In D. Banks, L. House, F.R. McMorris, P. Arabie, W. Gaul (Eds). Classification, Clustering and Data Mining Applications. Springer-Verlag Berlin-Heidelberg, 639-648.
data(hepatitis) #--------Mean Imputation---------- ce.impute(hepatitis,"mean",1:19)