predict.msda: make predictions from a "msda" object.

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/predict.msda.R

Description

This functions predicts class labels from a fitted msda object.

Usage

1
2
## S3 method for class 'msda'
predict(object, newx, ...)

Arguments

object

fitted msda model object.

newx

matrix of new values for x at which predictions are to be made. NOTE: newx must be a matrix, predict function does not accept a vector or other formats of newx.

...

Not used. Other arguments to predict.

Value

predicted class label(s) at the entire sequence of the penalty parameter lambda used to create the model.

Author(s)

Qing Mai <[email protected]>, Yi Yang <[email protected]>, Hui Zou <[email protected]>
Maintainer: Yi Yang <[email protected]>

References

Mai, Q.*, Yang, Y.*, and Zou, H. (2014), "Multiclass Sparse Discriminant Analysis." Submitted to Journal of the American Statistical Association. (* co-first author)

URL: https://github.com/emeryyi/msda

See Also

msda

Examples

1
2
3
4
5
data(GDS1615)
x<-GDS1615$x
y<-GDS1615$y
obj <- msda(x = x, y = y)
pred<-predict(obj,x)

emeryyi/msda documentation built on May 13, 2017, 5:12 p.m.