factorsparsetest {FAS}R Documentation

Test of the factor model against factor augmented sparse alternative

Description

Test of the factor model against factor augmented sparse alternative

Usage

factorsparsetest(x, y, w = NULL, q.levels = c(0.90, 0.95, 0.99), 
                 p.value = FALSE, rmax = 10, ...)

Arguments

x

T by p data matrix, where T and p respectively denote the sample size and the number of regressors.

y

T by 1 response variable.

w

T BY k additional regressors added in to the factor model under H0.

q.levels

quantile levels of effective noise.

p.value

whether pvalue should be computed. Default is FALSE.

rmax

maximum number of factors. Use in eigenvalue ratio estimator. Default is 10.

...

other arguments that can be passed to lassofit.

Details

Computes the test statistic and the p-value for testing the factor model against factor augmented sparse alternative. The number of factors are estimated by eigenvalue ratio estimator.

Value

factorsparsetest object.

Author(s)

Jonas Striaukas

Examples

set.seed(1)
x = matrix(rnorm(100 * 20), 100, 20)
beta = c(5,4,3,2,1,rep(0, times = 15))
y = x%*%beta + rnorm(100)
factorsparsetest(x = x, y = y)

[Package FAS version 1.0.0 Index]