SAR11

Notedocblock
SAR11(dgp_params, M_rows, N_cols, dist, dist_ao, prerun)

A struct to define a first-order spatial autoregressive (SAR(1, 1)) process:

\(\qquad \qquad Y_{t_1, t_2}=\alpha_1 \cdot Y_{t_1-1, t_2}+\alpha_2 \cdot Y_{t_1, t_2-1}+\alpha_3 \cdot Y_{t_1-1, t_2-1}+\varepsilon_{t_1, t_2}\)

Yₜ₁,ₜ₂ = α₁  Yₜ₁₋₁,ₜ₂ + α₂  Yₜ₁,ₜ₂₋₁ + α₃  Yₜ₁₋₁,ₜ₂₋₁ + εₜ₁,ₜ₂
  • dgp_params::Tuple(α₁::Float64, α₂::Float64, α₃::Float64) The requirements to guarantee stationarity for the process are |α₁| < 1, |α₂| < 1, |α₁ + α₂| < 1 - α₃, and |α₁ - α₂| < 1 + α₃.
  • m::Int: The number of rows for the final “SOP” matrix. Note that the final spatial matrix (“picture”) equals m + 1.
  • n::Int: The number of columns for the final “SOP” matrix. Note that the final spatial matrix (“picture”) equals n + 1.
  • prerun::Int: A value to initialize the DGP to achieve stationarity. These number of rows and columns will be discarded after the initialization.
  • dist::Distribution: A distribution for . You can use any univariate distribution from the Distributions.jl package.
  • dist_ao::Union{Nothing, Distribution}: Nothing or a distribution for additive outliers. For additive outliers you can use any univariate distribution from the Distributions.jl package.
  • prerun::Int: A value to initialize the DGP to guarantee stationarity. These number of rows and columns will be discarded for the final spatial matrix.
sar11 = SAR11((0.5, 0.3, 0.2), 11, 11, Normal(0, 1), nothing, 100)