gen.sim: Generate ordinal multivariate time series data

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/gen.sim.R

Description

Generating data from time series chain graphical model with vector autoregressive model of order 1.

Usage

1
gen.sim(t = NULL, n = NULL, p = NULL, k = NULL, network = NULL, prob0 = NULL)

Arguments

t

The number of time points.

n

The number of sample size (observations). The default value is 200.

p

The number of variables. The default value is 90.

k

The number of categories in the data. The default value is 5.

network

Specifies the type of network structure. This could be random, scale-free, hub or user defined structures. Details on simultions from the various network structures can be found in the R package flare.

prob0

Initial sparsity level.

Value

An object with S3 class "gen.sim" is returned:

data

A simulated time-series data.

true_theta

Sparse precision matrix.

true_gamma

Sparse autoregressive coefficients matrix.

true_sigma

Covariance matrix.

Author(s)

Pariya Behrouzi and Fentaw Abegaz
Maintainer: Pariya Behrouzi <pariya.behrouzi@gmail.com>

References

1. Behrouzi, P., and Wit, E. C. (2017c). netgwas: An R Package for Network-Based Genome-Wide Association Studies. arXiv preprint, arXiv:1710.01236.

See Also

tsnetwork

Examples

1
2
3
4
dat <- gen.sim(t = 2, n = 10, p = 5, k = 2, network = "hub")
sim <- dat$data1
prec.true <- dat$theta
autoR.true<- dat$gamma

tsnetwork documentation built on March 26, 2020, 6:45 p.m.