Learn R Programming

facmodTS (version 1.0)

predict.tsfmUpDn: Predicts asset returns based on a fitted up and down market time series factor model

Description

S3 predict method for object of class tsfmUpDn. It calls the predict.tsfm method for a list object of Up and Dn

Usage

# S3 method for tsfmUpDn
predict(object, ...)

Value

predict.tsfmUpDm produces a list of Up and Dn. Both Up and Dn contain a vector or a matrix of predictions.

Arguments

object

an object of class tsfmUpDn produced by fitTsfmUpDn.

...

optional arguments passed to predict.lm or predict.lmrob, such as se.fit, or, to predict.lars such as mode.

Author

Yi-An Chen and Sangeetha Srinivasan

See Also

predict.tsfm,fitTsfmUpDn, summary.tsfmUpDn

Examples

Run this code
 # load data
data(managers, package = 'PerformanceAnalytics')

# fit the factor model with LS. example: Up and down market factor model with LS fit
fitUpDn <- fitTsfmUpDn(asset.names = colnames(managers[,(1:6)]),
                       mkt.name = "SP500 TR",
                       data = managers, 
                       fit.method = "LS")
 
predict(fitUpDn)

Run the code above in your browser using DataLab