splinebasis: For each column of an input matrix, elements which are less...

View source: R/splinebasis.R

splinebasisR Documentation

For each column of an input matrix, elements which are less than the median of that column are set to 0, leaving the rest of the elements unchanged

Description

For each column of an input matrix, elements which are less than the median of that column are set to 0, leaving the rest of the elements unchanged.

Usage

splinebasis(X)

Arguments

X

The extra covariates, a n x K matrix. No constant included.

Value

H A n x K matrix. All elements of the X that are less than the median of their corresponding columns are set to 0, leaving the rest unchanged.

Examples

library(pracma)
X <- rand(4,4)
H <- splinebasis(X = X)


drcarlate documentation built on July 9, 2023, 6:16 p.m.