coef.treeda: Coefficients from treeda fit

Description Usage Arguments Value Examples

Description

Returns the coefficients from a treeda fit either in terms of the leaves only or in terms of the nodes and leaves.

Usage

1
2
## S3 method for class 'treeda'
coef(object, type = c("leaves", "nodes"), ...)

Arguments

object

An object of class treeda.

type

Should the coefficients be in the leaf space or the node space?

...

Not used.

Value

A Matrix object containing the coefficients.

Examples

1
2
3
4
5
6
7
data(treeda_example)
out.treeda = treeda(response = treeda_example$response,
    predictors = treeda_example$predictors,
    tree = treeda_example$tree,
    p = 1)
coef(out.treeda, type = "leaves")
coef(out.treeda, type = "nodes")

treeDA documentation built on May 2, 2019, 5:42 a.m.