Description Usage Arguments Value Examples
This functions extracts coefficients from a "rcar" or "cv.rcar" object at a single value of lambda.
1 2 | ## S3 method for class 'rcar'
coef(object, lambd)
|
object: |
"rcar" or "cv.rcar" object. |
lambd: |
Value of the penalty parameter lambda at which coefficients extraction is required. If not specified, the programme use the value of lambda corresponding the minimum mean cross-validated error. |
The function returns the retained rules and their corresponding parameters.
1 2 3 4 5 6 7 8 9 10 11 12 | vote.rcar.1<-rcar(vote, y.rank = 1, s=0.2, c=0.8,lambd=0.169)
vote.rcar.2<-rcar(vote, y.rank = 1, s=0.2, c=0.8)
coef.rcar(vote.rcar.1)
coef.rcar(vote.rcar.2, lambd = 0.169)
vote.cv<-cv.rcar(vote, y.rank = 1, s=0.2, c=0.8)
coef.rcar(vote.cv, lambd=0.169)
coef.rcar(vote.rcar)
If the value of lambda is not specified, the programme uses the value of lambda corresponding the minimum mean cross-validated error.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.