psfmi_coxr_bw: Backward selection of Cox regression models in multiply...

View source: R/psfmi_coxr_bw.R

psfmi_coxr_bwR Documentation

Backward selection of Cox regression models in multiply imputed data.

Description

psfmi_coxr_bw Backward selection of Cox regression models in multiply imputed data using selection methods RR, D1, D2 and MPR. Function is called by psfmi_coxr.

Usage

psfmi_coxr_bw(
  data,
  nimp,
  impvar,
  status,
  time,
  P,
  p.crit,
  method,
  keep.P,
  strata.P
)

Arguments

data

Data frame with stacked multiple imputed datasets. The original dataset that contains missing values must be excluded from the dataset. The imputed datasets must be distinguished by an imputation variable, specified under impvar, and starting by 1.

nimp

A numerical scalar. Number of imputed datasets. Default is 5.

impvar

A character vector. Name of the variable that distinguishes the imputed datasets.

status

The status variable, normally 0=censoring, 1=event.

time

Follow up time.

P

Character vector with the names of the predictor variables. At least one predictor variable has to be defined. Give predictors unique names and do not use predictor name combinations with numbers as, age2, BMI10, etc.

p.crit

A numerical scalar. P-value selection criterium. A value of 1 provides the pooled model without selection.

method

A character vector to indicate the pooling method for p-values to pool the total model or used during predictor selection. This can be "RR", D1", "D2" or "MPR". See details for more information. Default is "RR".

keep.P

A single string or a vector of strings including the variables that are forced in the model during predictor selection. All type of variables are allowed.

strata.P

A single string including the strata variable.

Author(s)

Martijn Heymans, 2020


psfmi documentation built on July 9, 2023, 7:02 p.m.