predict.curvir {curvir} | R Documentation |
Predict method for curvir reserve demand models
Description
Predicted values based on curvir model object
Predicted values based on npcurvir model object
Usage
## S3 method for class 'curvir'
predict(object, newdata = NULL, newdummy = NULL, ...)
## S3 method for class 'npcurvir'
predict(object, newdata = NULL, newdummy = NULL, ...)
Arguments
object |
A model fit with |
newdata |
New input data organised as the x matrix in |
newdummy |
New input dummy organised as the dummy vector in |
... |
Further arguments (unused) |
Value
Returns a matrix of predicted values. If the model has estimates for intervals then it will provide upper and lower intervals.
Returns a matrix of predicted values. If the model has estimates for intervals then it will provide upper and lower intervals.
Methods (by class)
-
predict(curvir)
: Predicted values for parametric curves -
predict(npcurvir)
: Predicted values for non-parametric curves
Author(s)
Nikolaos Kourentzes, nikolaos@kourentzes.com
References
Chen, Z., Kourentzes, N., & Veyrune, R. (2023). Modeling the Reserve Demand to Facilitate Central Bank Operations. IMF Working Papers, 2023(179).
See Also
Examples
# Use ECB example data
rate <- ecb$rate
x <- ecb$x[,1,drop=FALSE]
fit <- curve(x,rate)
predict(fit)
# An example with new data
predict(fit,newdata=tail(x))
# Use ECB example data
rate <- ecb$rate
x <- ecb$x[,1,drop=FALSE]
fit <- npcurve(x,rate)
predict(fit)