Fits a univariate Cox model for a continuous predictor and returns the HR, 95% CI, and Wald p-value.

cox_univar_fun_cts(data_fun, res_time, res_event, var)

Arguments

data_fun

Data frame containing survival data.

res_time

Character. Name of survival time variable.

res_event

Character. Name of event indicator (1 = event, 0 = censored).

var

Character. Categorical predictor variable.

Value

A single-row matrix of HR and p-value.

Examples

if (FALSE) { # \dontrun{
cox_univar_fun_cts(mydata, "OS_time", "OS_event", "Age")
} # }