Learn R Programming

MissingDataGUI (version 0.1-2)

singleimputation: Impute the Data Without Consideration of Conditions.

Description

This function is to impute missing data by one of the eight methods without the condition. When the condtions are imported, they are then romoved from the data frame, and then the imputation will be applied without conditions. Details of the eight methods can be found in imputation.

Usage

singleimputation(dat, method, vartype, cond)

Arguments

dat
A data frame whose missing values need to be imputed. The last column should be the row number passed by imputation.
method
The imputation method selected from the missing data GUI. Must be one of 'Below 10 neighbor','Multiple Imputation','Mode'.
vartype
A vector of the classes of dat. The length is the same as the number of columns of dat. The value should be from "integer", "numeric", "factor", and "character".
cond
A vector of categorical variables. There are no missing values in those variables.

Value

  • The imputed data frame with a column of row numbers matching with the last column of dat, to pass back to imputation.

Details

See imputation.