accuracy.smooth | R Documentation |
Function produces error measures for the provided object and the holdout values of the
response variable. Note that instead of parameters x
, test
, the function
accepts the vector of values in holdout
. Also, the parameters d
and D
are not supported - MASE is always calculated via division by first differences.
## S3 method for class 'smooth'
accuracy(object, holdout = NULL, ...)
## S3 method for class 'smooth.forecast'
accuracy(object, holdout = NULL, ...)
object |
The estimated model or a forecast from the estimated model generated via
either |
holdout |
The vector of values of the response variable in the holdout (test) set.
If not provided, then the function will return the in-sample error measures. If the
|
... |
Other variables passed to the |
The function is a wrapper for the measures function and is implemented for convenience.
Ivan Svetunkov, ivan@svetunkov.ru
y <- rnorm(100, 100, 10)
ourModel <- adam(y, holdout=TRUE, h=10)
accuracy(ourModel)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.