View source: R/ordinalNet-methods.R
predict.ordinalNet | R Documentation |
Obtains predicted probabilities, predicted class, or linear predictors.
## S3 method for class 'ordinalNet' predict( object, newx = NULL, whichLambda = NULL, criteria = c("aic", "bic"), type = c("response", "class", "link"), ... )
object |
An "ordinalNet" S3 object. |
newx |
Optional covariate matrix. If NULL, fitted values will be obtained
for the training data, as long as the model was fit with the argument
|
whichLambda |
Optional index number of the desired lambda value within the solution path sequence. |
criteria |
Selects the best lambda value by AIC or BIC. Only used
if |
type |
The type of prediction required. Type "response" returns a matrix of fitted probabilities. Type "class" returns a vector containing the class number with the highest fitted probability. Type "link" returns a matrix of linear predictors. |
... |
Not used. Additional predict arguments. |
The object returned depends on type
.
ordinalNet
# See ordinalNet() documentation for examples.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.