JS.uni_m: A complete table for multiple univariable survival analysis

Description Usage Arguments Value Examples

View source: R/JSuni_m.R

Description

JS.uni_m output the table with general multivariable survival analysis result with Number of total patients, Number of Events, HR (95% Confidence Interval),P value. This function only change the format of the output table. Note: c index and d index are from package survcomp.

Usage

1
JS.uni_m(Data, Event, Stime, Svars, Cats, Groupns, EM = F)

Arguments

Event

The status indicator, normally 0=alive, 1=dead

Stime

This is the follow up time

Svars

A vector of variables

Cats

a vector of logical elements indicating whether or not Svar is a categorical varaible

EM

a logcial term, include estimated median survival nor not

D

A data.frame in which to interpret the variables

groupns

A text vector of the the group names for output

Value

A dataframe of coxph output including Number of total patients, Number of Events, HRs (95% Confidence Intervals), P values, C index and D index.

Examples

1
2
3
4
5
6
Event   <- c("pd_censor")
Stime   <- c("pd_surv")
Svars   <- c("tr_group", "age_m")
Cats    <- c(T, F)
Groupns <- c("Treatment", "Age")
JS.uni_m(D, Event, Stime, Svars, Cats, Groupns)

SophiaJia/Jsurvformat1.2 documentation built on May 10, 2017, 2:33 p.m.