Description Usage Arguments Details Value Author(s) Examples
Reset the arguments to be sent to the prediction method. This capability is intended for package developers making use of the “model object" framework.
1 2 | ## S4 replacement method for signature 'modelObj'
predictorArgs(object) <- value
|
object |
object of class modelObj, for which the arguments sent to the prediction method are to be reset. |
value |
A named list containing the new arguments to be sent to the prediction method. |
The first two elements of the list contain the name for the object returned by the regression method and the name for the data.frame for which predictions are desired. buildModelObj creates modelObj using an internal convention, which is critical to the correct implementation of this package. These two elements should not be changed and will be carried over from the original argument list.
modelObj with an updated argument list to be passed to the prediction method.
Shannon T. Holloway <sthollow@ncsu.edu>
1 2 3 4 5 6 7 8 9 10 11 12 | #----------------------------------------------------#
# Create modeling object using a formula
#----------------------------------------------------#
mo <- buildModelObj(model=Y ~ X1 + X2 + X3 + X4,
solver.method='lm',
predict.method='predict.lm',
predict.args=list(type='response'))
predictorArgs(mo)
argList <- list("type"='terms')
predictorArgs(mo) <- argList
predictorArgs(mo)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.