getetmat {TSLA}R Documentation

Tree-guided expansion

Description

Give the expanded design matrix and the expanded tree structure by adding interactions in conformity to the structure.

Usage

getetmat(tmatrix, dmatrix)

Arguments

tmatrix

Tree structure of the original features in matrix form.

dmatrix

Original design matrix in matrix form.

Details

This function is used by the TSLA method only when the penalty is selected as "CL2". The all zero columns produced by the interactions are excluded in the output.

For the TSLA method, the signs of the coefficients in the linear constraints depend on the order of the term. To better extend the method in implementation, we apply the signs on the feature vectors instead of the regression coefficients. For example, we use feature vector -x_{12} instead of x_{12}. The expanded design matrix x.expand from this function is adjusted by the signs. The A matrix and all the coefficients estimated from the package can be explained correspondingly. We also provide x.expand.adj, A.adj, and beta.coef.adj as the quantities with the effects of the signs removed.

The input tree structure of the original features needs to be constructed as the following: each row corresponds to a variable at the finest level; each column corresponds to an ordered classification level with the leaf level at the left-most and the root level at the right-most; the entry values in each column are the index of the ancestor node of the variable at that level. As we move from left to right, the number of unique values in the column becomes fewer.

Value

A list.

x.expand

The design matrix after expansion. Each column is multiplied by (-1)^{r-1}, where r is the order of the corresponding interaction term.

tree.expand

The tree structure after expansion.

x.expand.adj

The design matrix after expansion with the effects of signs removed.


[Package TSLA version 0.1.2 Index]