Learn R Programming

hdnom (version 5.0)

hdnom.varinfo: Extract Information of Selected Variables from High-Dimensional Cox Models

Description

Extract the names and type of selected variables from established high-dimensional Cox models.

Usage

hdnom.varinfo(object, x)

Arguments

object

Model object fitted by hdcox.*() functions.

x

Data matrix used to fit the model.

Value

A list containing the index, name, type and range of the selected variables.

Examples

Run this code
# NOT RUN {
library("survival")

# Load imputed SMART data
data("smart")
x = as.matrix(smart[, -c(1, 2)])
time = smart$TEVENT
event = smart$EVENT
y = Surv(time, event)

# Fit Cox model with lasso penalty
fit = hdcox.lasso(x, y, nfolds = 5, rule = "lambda.1se", seed = 11)
hdnom.varinfo(fit, x)
# }

Run the code above in your browser using DataLab