generateData {pmhtutorial}R Documentation

Generates data from a linear Gaussian state space model

Description

Generates data from a specific linear Gaussian state space model of the form xt=ϕxt1+σvvt x_{t} = \phi x_{t-1} + \sigma_v v_t and yt=xt+σeet y_t = x_t + \sigma_e e_t , where vtv_t and ete_t denote independent standard Gaussian random variables, i.e. N(0,1)N(0,1).

Usage

generateData(theta, noObservations, initialState)

Arguments

theta

The parameters θ={ϕ,σv,σe}\theta=\{\phi,\sigma_v,\sigma_e\} of the LGSS model. The parameter ϕ\phi that scales the current state in the state dynamics is restricted to [-1,1] to obtain a stable model. The standard deviations of the state process noise σv\sigma_v and the observation process noise σe\sigma_e must be positive.

noObservations

The number of time points to simulate.

initialState

The initial state.

Value

The function returns a list with the elements:

Author(s)

Johan Dahlin uni@johandahlin.com

References

Dahlin, J. & Schon, T. B. "Getting Started with Particle Metropolis-Hastings for Inference in Nonlinear Dynamical Models." Journal of Statistical Software, Code Snippets, 88(2): 1–41, 2019.


[Package pmhtutorial version 1.5 Index]