Learn R Programming

imputation (version 2.0.3)

lmImpute: Locally Weighted Linear Imputation

Description

Fill missing values in a column by running a locally weighted least squares regression against the row number. Good for large data (large number of records)

Usage

lmImpute(x, ...)

Arguments

x
a data frame or matrix where each row represents a different record
...
additional parameters passed to locfit

Examples

Run this code
x = matrix(rnorm(100),10,10)
  x.missing = x > 1
  x[x.missing] = NA
  lmImpute(x)

Run the code above in your browser using DataLab