Skip to contents

Imputes partial dates in DCUTDTC variable, created within the datacut process.

Usage

impute_dcutdtc(dsin, varin, varout)

Arguments

dsin

Name of input dataframe

varin

Name of input datacut date variable

varout

Name of imputed output variable

Value

Returns the input dataframe, with the additional of one extra variable (varout) which is the imputed version of varin.

Examples

dcut <- data.frame(
  USUBJID = c("UXYZ123a", "UXYZ123b", "UXYZ123c", "UXYZ123d"),
  DCUTDTC = c("2022-06-23", "2022-06-23T16", "2022-06-23T16:57", "2022-06-23T16:57:30")
)
dcut_final <- impute_dcutdtc(dsin = dcut, varin = DCUTDTC, varout = DCUTDTM)