Abstract

This paper introduces ARCHModels.jl, a package for the Julia programming language that implements a number of univariate and multivariate ARCH-type models. This model class is the workhorse tool for modelling the conditional volatility of financial assets. Their distinguishing feature is that they model the latent volatility as a (deterministic) function of past returns and volatilities. This recursive structure results in loop-heavy code which, due to its just-in-time compiler, Julia is well-equipped to handle. As such, the entire package is written in Julia, without any binary dependencies. We benchmark the performance of ARCHModels.jl against popular implementations in MATLAB, R, and Python, and illustrate its use in a detailed case study.

Highlights

  • Financial returns data at daily or higher frequency display a number of stylized facts, including volatility clustering (large returns tend to cluster together), heavy tails, and statistical leverage, among others; see Figure 1 for an example

  • Unlike the other mean specifications, a regression requires external data, which the constructor expects as a matrix with observations in rows and variables in columns, as follows: julia> reg = Regression(ones(100, 1)); In this example, we created a regression model containing one regressor, given by a column of ones; this is equivalent to including an intercept in the model

  • Example: julia> am3 = simulate( GARCH{1, 1}([1., .9, .05]), 1000; warmup=500, meanspec=Intercept(5.), dist=Student’s t (StdT)(3.) ); julia> am4 = simulate(am3, 1000); Care must be taken if the mean specification has a notion of sample size, as in the case of Regression: because the sample size must match that of the data to be simulated, one must pass warmup=0, or an error will be thrown

Read more

Summary

Introduction

Financial returns data at daily or higher frequency display a number of stylized facts, including volatility clustering (large (in absolute value) returns tend to cluster together), heavy tails, and statistical leverage, among others; see Figure 1 for an example. The GARCH model extends the ARCH model (in which β = 0) of Engle (1982), who in 2003 was awarded a Nobel Memorial Prize in Economic Sciences for its development Due to their popularity, the ARCH model and its various extensions have been implemented in many commercial and free programming environments; examples include the rugarch (Ghalanos, 2019) package for R (R Core Team, 2019), the ARCH (Sheppard and other contributors, 2019) package for Python (van Rossum, 1995), and MATLAB’s (The MathWorks Inc., 2019) Econometrics toolbox.

ARCH models
Univariate type hierarchy
Volatility specifications
Mean specifications
Distributions
Working with UnivariateARCHModels
Multivariate type hierarchy
Covariance specifications
Univariate Modelling
Numerical results
Benchmarks
Summary
Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call