localImputation: Function to generate imputations using non-parametric and...

View source: R/local_imputaiton.R

localImputationR Documentation

Function to generate imputations using non-parametric and semi-parametric local imputation methods.

Description

Function to generate imputations using non-parametric and semi-parametric local imputation methods.

Usage

localImputation(
  i,
  preds,
  y,
  delta,
  bw = NULL,
  kernel = c("gaussian", "uniform", "triangular")
)

Arguments

i

integer referring to the index of the missing value to be imputed.

preds

numeric vector of predictions of missing values from SuperLearner.

y

numeric vector for variable to be imputed.

delta

binary vector of length length(y) indicating missingness. 1 where y is observed and 0 where y is missing.

bw

NULL or numeric value for bandwidth of kernel function (as standard deviations of the kernel).

kernel

one of gaussian, uniform, or triangular. Specifies the kernel to be used in estimating the distribution around a missing value.

Value

numeric vector of randomly drawn imputed values.


abshev/superMICE documentation built on May 10, 2022, 11:27 a.m.