mi_coxph: Coxph with multiple imputed values

View source: R/mi_coxph.R

mi_coxphR Documentation

Coxph with multiple imputed values

Description

This code generates a coxph model with multiple imputed values for missing data. Imputation is conducted with the mice::mice() function. Pooled results obtained with mice::pool() and respective pvalues and 95% CIs are presented as results.

Usage

mi_coxph(data, time, status, vars, prop.var = NULL, m = 5, ...)

Arguments

data

data.frame or data.table containing survival data.

time

the time interval from start of observation until date of event (e.g. disease progression or death) or censoring.

status

variable specifying if event occured or data has been censored.

vars

variables tested for Influence on outcome.

prop.var

variable for which propensity scores should be calculated. If no value is provided (prop.var = NULL), no weights are used in coxph. Default is NULL.

m

Number of multiple imputations. The default is m=5.

...

additional arguments to be passed on to coxph function


MBender1992/emR documentation built on Feb. 18, 2025, 9:21 a.m.