Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

coxphmulti

Cox proprotional hazards multivariable models: finalfit model wrapper


Description

Using finalfit conventions, produces multivariable Cox Proportional Hazard regression models for a set of explanatory variables against a survival object.

Usage

coxphmulti(.data, dependent, explanatory)

Arguments

.data

Data frame.

dependent

Character vector of length 1: name of survival object in form Surv(time, status).

explanatory

Character vector of any length: name(s) of explanatory variables.

Details

Uses coxph with finalfit modelling conventions. Output can be passed to fit2df.

Value

A multivariable coxph fitted model output. Output is of class coxph.

See Also

Examples

# Cox Proportional Hazards multivariable analysis.
library(finalfit)
library(dplyr)

explanatory = c("age.factor", "sex.factor", "obstruct.factor", "perfor.factor")
dependent = "Surv(time, status)"
colon_s %>%
	coxphmulti(dependent, explanatory) %>%
	fit2df()

finalfit

Quickly Create Elegant Regression Results Tables and Plots when Modelling

v1.0.2
MIT + file LICENCE
Authors
Ewen Harrison [aut, cre], Tom Drake [aut], Riinu Ots [aut]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.