iter_get_cox_res: Runs get_cox_res Over a Range of Features

Description Usage Arguments Value Examples

View source: R/iter_get_cox_res.R

Description

This is a modified version of get_cox_res allowing for multiple runs of get_cox_res.

Usage

1
2
iter_get_cox_res(in.df, endpoint, endpoint.code, features,
  broom.fun = c("tidy", "glance"), group = NULL)

Arguments

in.df

Input data.frame.

endpoint

Column name of the endpoint.

endpoint.code

Column name of the endpoint status code.

features

This must be a list of features.

broom.fun

Which broom function to run on the cox regression results.

group

Column name containing the groups to run cox regression on. If, specified, cox regression is run separately for each group.

Value

List of data frames with each data frame being the output of get_cox_res.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
library("survival")
endpoint <- "time"
endpoint.code <- "status"

# Run Cox Regression on List of Features
features <- list(c("age", "obstruct"),
                 c("nodes"))

iter_get_cox_res(colon, endpoint, endpoint.code, features,
                  group = "rx")

survutils documentation built on July 23, 2018, 1:02 a.m.