classo {robregcc} | R Documentation |
Estimate parameters of linear regression model with compositional covariates using method suggested by Pixu shi.
Description
The model uses scaled lasoo approach for model selection.
Usage
classo(Xt, y, C, we = NULL, type = 1, control = list())
Arguments
Xt |
CLR transformed predictor matrix. |
y |
model response vector |
C |
sub-compositional matrix |
we |
specify weight of model parameter |
type |
1/2 for l1 / l2 loss in the model |
control |
a list of internal parameters controlling the model fitting |
Value
beta |
model parameter estimate |
References
Shi, P., Zhang, A. and Li, H., 2016. Regression analysis for microbiome compositional data. The Annals of Applied Statistics, 10(2), pp.1019-1040.
Examples
library(robregcc)
library(magrittr)
data(simulate_robregcc)
X <- simulate_robregcc$X;
y <- simulate_robregcc$y
C <- simulate_robregcc$C
n <- nrow(X); p <- ncol(X); k <- nrow(C)
# Predictor transformation due to compositional constraint:
Xt <- cbind(1,X) # accounting for intercept in predictor
C <- cbind(0,C) # accounting for intercept in constraint
bw <- c(0,rep(1,p)) # weight matrix to not penalize intercept
# Non-robust regression, [Pixu Shi 2016]
control <- robregcc_option(maxiter = 5000, tol = 1e-7, lminfac = 1e-12)
fit.nr <- classo(Xt, y, C, we = bw, type = 1, control = control)
[Package robregcc version 1.1 Index]