Learn R Programming

SDModels (version 1.0.10)

get_cp_seq.SDTree: Get the sequence of complexity parameters of an SDTree

Description

This function extracts the sequence of complexity parameters of an SDTree that result in changes of the tree structure if pruned. Only cp values that differ in the first three digits after the decimal point are returned.

Usage

# S3 method for SDTree
get_cp_seq(object, ...)

Value

A sequence of complexity parameters

Arguments

object

an SDTree object

...

Further arguments passed to or from other methods.

Author

Markus Ulmer

See Also

regPath stabilitySelection

Examples

Run this code

set.seed(1)
n <- 10
X <- matrix(rnorm(n * 5), nrow = n)
y <- sign(X[, 1]) * 3 + rnorm(n)
model <- SDTree(x = X, y = y, Q_type = 'no_deconfounding', cp = 0)
get_cp_seq(model)

Run the code above in your browser using DataLab