Description Usage Arguments Value Author(s) References Examples

View source: R/mainFunctions.R

Similar to cv.rq.pen function, but uses group penalty. Group penalties use the L1 norm instead of L2 for computational convenience. QICD is a group penalty extension of the algorithm presented by Peng and Wang (2015). LP does a linear programming version of the group penalty.

1 2 3 4 5 |

`x` |
Matrix of predictors. |

`y` |
Vector of response values. |

`groups` |
Vector assigning columns of x to groups. |

`tau` |
Conditional quantile being modelled. |

`lambda` |
Vector of lambdas. Default is for lambdas to be automatically generated. |

`penalty` |
Type of penalty: "LASSO", "SCAD" or "MCP". |

`intercept` |
Whether model should include an intercept. Constant does not need to be included in "x". |

`criteria` |
How models will be evaluated. Either cross-validation "CV", BIC "BIC" or large P BIC "PBIC". |

`cvFunc` |
If cross-validation is used how errors are evaluated. Check function "check", "SqErr" (Squared Error) or "AE" (Absolute Value). |

`nfolds` |
K for K-folds cross-validation. |

`foldid` |
Group id for cross-validation. Function will randomly generate groups if not specified. |

`nlambda` |
Number of lambdas for which models are fit. |

`eps` |
Smallest lambda used. |

`init.lambda` |
Initial lambda used to find the maximum lambda. Not needed if lambda values are set. |

`alg` |
Algorithm used for fit. "QICD" or "LP". |

`penGroups` |
Specify which groups will be penalized. Default is to penalize all groups. |

`...` |
Additional arguments to be sent to rq.group.fit or groupQICDMultLambda. |

Returns the following:

`beta` |
Matrix of coefficients for different values of lambda |

`residuals` |
Matrix of residuals for different values of lambda. |

`rho` |
Vector of rho, unpenalized portion of the objective function, for different values of lambda. |

`cv` |
Data frame with "lambda" and second column is the evaluation based on the criteria selected. |

`lambda.min` |
Lambda which provides the smallest statistic for the selected criteria. |

`penalty` |
Penalty selected. |

`intercept` |
Whether intercept was included in model. |

`groups` |
Group structure for penalty function. |

Ben Sherwood

[1] Yuan, M. and Lin, Y. (2006). Model selection and estimation in regression with grouped variables. *J. R. Statist. Soc. B*, **68**, 49-67.

[2] Peng, B. and Wang, L. (2015). An Iterative Coordinate Descent Algorithm for High-Dimensional Nonconvex Penalized Quantile Regression. *Journal of Computational and Graphical Statistics*, **24**, 676-694.

1 2 3 4 5 6 7 |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.