Skip to contents

This RLDM (Rational Linear Dynamic Models) R package provides models for stationary processes with a rational spectral density and methods for their estimation. We will refer to them as rational models. It builds heavily on its sister R package rationalmatrices, see https://bfunovits.github.io/rationalmatrices/.

Installation

You can install the latest version of the code using the remotes R package.

remotes::install_github("bfunovits/RLDM")

Content

The package provides the following sets of functions whose documentation can be found in the reference page https://bfunovits.github.io/RLDM/reference of the website https://bfunovits.github.io/RLDM/ (created with https://pkgdown.r-lib.org/):

  • Classes for the construction of rational models (consisting of an input covariance matrix and a rational matrix function from the rationalmatrices package):
    • VARMA models armamod()
    • State space models stspmod()
    • Right matrix fraction description (RMFD) models rmfdmod() (which is experimental)
  • Templates for filling the linear parameters with deep parameters through an affine mapping. Consists of
    • a matrix HH where the number of rows is the number of linear parameters in a given model and the number of columns is the number of deep parameters in a given model
    • a column vector hh of appropriate dimension

See help("model structures") and help("local model structures") for more details.

Getting Started

RLDM includes comprehensive documentation organized by user level:

  1. New to RLDM? Start with vignette("0_getting_started")
    • Practical introduction with simple examples
    • AR models and multivariate VAR/VARMA systems
    • ~10-15 minute read with executable code
  2. Want a complete workflow example? See vignette("1_case_study")
    • Blanchard-Quah economic data analysis
    • Comparing AR, state space, and ARMA models
    • Model selection, diagnostics, and forecasting
  3. Need technical details? Consult vignette("2_technical_reference")
    • Complete class and method documentation
    • Mathematical foundations
    • Method selection guidance

Installation Notes

The package depends on rationalmatrices. Install both:

remotes::install_github("bfunovits/rationalmatrices")
remotes::install_github("bfunovits/RLDM")

Vignette Building: To build vignettes locally, you need pandoc-citeproc installed on your system: - Ubuntu/Debian: sudo apt-get install pandoc-citeproc - macOS: brew install pandoc-citeproc - Windows: Included in pandoc installer

Pre-built vignettes are available on the package website.

Then load and explore:

library(RLDM)
browseVignettes("RLDM")  # View all vignettes (if built locally)
vignette("0_getting_started")  # Access specific vignette