Learn R Programming

SurvBoost (version 0.1.2)

plot.boosting: Boosting plot function

Description

This function allows you to visualize the coefficient paths of the boosting algorithm.

Usage

# S3 method for boosting
plot(x, y = NULL, type = "frequency", ...)

Arguments

x

output from the boosting_core function.

y

y coordinates of plot, default is NULL.

type

specifies type of coefficient plot. Default value is frequency which plots the proportion of variables selected. Alternatively type set to "coefficients" plots the coefficient path for each variable.

...

ignored

Examples

Run this code
# NOT RUN {
data <- simulate_survival_cox(true_beta=c(1,1,1,1,1,0,0,0,0,0))
formula <- as.formula("Surv(time,delta) ~ strata(strata_idx) + V1 + V2 + 
V3 + V4 + V5 + V6 + V7 + V8 + V9 + V10" )
boosting.output <- boosting_core(formula, data, rate=0.1, num_iter=500)
plot.boosting(boosting.output)
plot.boosting(boosting.output, type="coefficients")

# }

Run the code above in your browser using DataLab