has_tdc: Extract time-dependent covariates from data set

Description Usage Arguments Value

Description

For all covariates in the data set, this functions checks if the values of the covariate changes per ID or other grouping variable. Returns the names of variables that change over time.

Usage

1
has_tdc(data, id_var)

Arguments

data

A data frame (potentially) containing time-dependent covariates.

id_var

A character indicating the grouping variable. For each covariate it will be checked if their values change within a group specified by id_var.

Value

A character vector containing names of variables that are not constant in each group (id_var).


adibender/ped documentation built on Dec. 16, 2019, 12:33 a.m.