starma_sim: Simulate spatio-temporal data using a STARMA model

Description Usage Arguments Value References

Description

Generate a spatio-teporal dataset according to a STARMA model.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
starma_sim(
  model,
  klist,
  n,
  rand.gen = stats::rnorm,
  innov = NULL,
  seed = NULL,
  FUN = function(x) {     x },
  ...
)

Arguments

model

A list with components ar and ma. Each component contains a matrix of the coefficients where the first index corresponds to the row and the second index to the column.

klist

A list of matrices like the ones returned by consecutive use of spdep::dnearneigh and spdep::nblag where a value higher than 0 implies that the row and column locations are neighbours

n

The length of the time series to be generated

rand.gen

The random generator to be used. Defaults to stats::rnorm

innov

A matrix of initial innovations. Defaults to matrix(rand.gen(n*ncol(klist[[1]]), ...), n, ncol(klist[[1]]))

seed

A seed to set before generating the dataset. Defaults to NULL

FUN

A (possibly non-linear) function to apply to the matrix during STAR data generation.

...

Other parameters (?)

Value

A matrix where each column contains the data for a location, and each row contains the data for a time-stamp.

References

See example on page 3 of https://cran.r-project.org/web/packages/starma/starma.pdf


mrfoliveira/STEvaluation-MDPI2021 documentation built on Dec. 21, 2021, 10:07 p.m.