Book Image

Mastering R for Quantitative Finance

Book Image

Mastering R for Quantitative Finance

Overview of this book

Table of Contents (20 chapters)
Mastering R for Quantitative Finance
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Summary


In this chapter, we presented an intra-day volume forecasting model and its implementation in R using data from the DJIA index. Due to length limitations, we selected the one model from the literature that we believe is the most accurate when used to predict stock volumes. The model uses turnover instead of volume for convenience, and separates a seasonal component (U shape) and a dynamic component, and forecasts these two separately. The dynamic component is forecasted in two different ways, fitting an AR(1) and a SETAR model. Similarly to the original article, we do not declare one to be better than the other, but we visually show the results and find them to be acceptably accurate. The original article convincingly proves the model to be better than a carefully selected benchmark, but we leave it to the reader to examine that, because we only used a short data set for illustration, which is not suitable to obtain robust results.