ccglmreg | R Documentation |
Fit a linear model in penalized CC-family. The regularization path is computed for the lasso (or elastic net penalty), scad (or snet) and mcp (or mnet penalty), at a grid of values for the regularization parameter lambda.
## S3 method for class 'formula' ccglmreg(formula, data, weights, offset=NULL, contrasts=NULL, ...) ## S3 method for class 'matrix' ccglmreg(x, y, weights, offset=NULL, ...) ## Default S3 method: ccglmreg(x, ...)
formula |
symbolic description of the model, see details. |
data |
argument controlling formula processing
via |
weights |
optional numeric vector of weights. If |
x |
input matrix, of dimension nobs x nvars; each row is an observation vector |
y |
response variable. Quantitative for |
offset |
Not implemented yet |
contrasts |
the contrasts corresponding to |
... |
Other arguments passing to |
The sequence of robust models implied by lambda
is fit by the IRCO along with coordinate
descent. Note that the objective function is
weights*loss + λ*penalty,
if standardize=FALSE
and
\frac{weights}{∑(weights)}*loss + λ*penalty,
if standardize=TRUE
.
An object with S3 class "ccglmreg"
for the various types of models.
call |
the call that produced this object |
b0 |
Intercept sequence of length |
beta |
A |
lambda |
The actual sequence of |
nobs |
number of observations |
risk |
if |
pll |
if |
fitted.values |
predicted values depending on |
Zhu Wang <wangz1@uthscsa.edu>
Zhu Wang (2020) Unified Robust Estimation, arXiv e-prints, https://arxiv.org/abs/2010.02848
print
, predict
, coef
and plot
methods, and the cv.ccglmreg
function.
#binomial x=matrix(rnorm(100*20),100,20) g2=sample(c(-1,1),100,replace=TRUE) fit1=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="active", decreasing=TRUE,type.init="bst") #fit1$risk ## Not run: ### different solution paths via a combination of type.path, decreasing and type.init fit1=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="active", decreasing=TRUE,type.init="bst") fit2=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="active", decreasing=FALSE,type.init="bst") fit3=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="nonactive", decreasing=TRUE,type.init="bst") fit4=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="nonactive", decreasing=FALSE,type.init="bst") fit5=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="active", decreasing=TRUE,type.init="co") fit6=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="active", decreasing=FALSE,type.init="co") fit7=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="nonactive", decreasing=TRUE,type.init="co") fit8=ccglmreg(x,g2,s=1,cfun="ccave",dfun="gaussian",type.path="nonactive", decreasing=FALSE,type.init="co") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.