Description Usage Arguments Details Value Examples
Generate vector autoregression time series with 3 blockly correlated structure
1 |
p.block |
a list of 3 numbers. Number of covariates for each block. Default is 3, 3, 4 so they form a 10 series X. |
x0.block |
a list of 3 sublists. Each sublist contains vectors as the initial values |
A.block |
a list of 3 sublists. Each sublist contains AR coefficient matrices. |
t |
a number. Length of series, including the initial lags. |
sigmax |
a number. Standard deviation of noise of x. |
This function is based on XgenSimple
. 3 blocks, hence need specification for each block, and arguments p.block,
x0.block, A.block
should have length of 3.
It is recommended to use coef.mat
to generate the AR coefficient matrices.
a matrix
bigX |
The combined matrix of 3 individual submatrices |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | A11 <- coef.mat(dimension = 3, ondiag = 0.4, offdiag = 0.15)
A12 <- coef.mat(dimension = 3, ondiag = 0.1, offdiag = 0.07)
A13 <- coef.mat(dimension = 3, ondiag = 0.1, offdiag = 0)
A21 <- coef.mat(dimension = 3, ondiag = 0.4, offdiag = 0.15)
A22 <- coef.mat(dimension = 3, ondiag = 0.1, offdiag = 0.05)
A23 <- coef.mat(dimension = 3, ondiag = 0.1, offdiag = 0)
A31 <- coef.mat(dimension = 4, ondiag = 0.4, offdiag = 0.15)
A32 <- coef.mat(dimension = 4, ondiag = 0.1, offdiag = 0.05)
A33 <- coef.mat(dimension = 4, ondiag = 0.1, offdiag = 0)
A.block <- list(block1 = list(A1 = A11, A2 = A12, A3 = A13),
block2 = list(A1 = A21, A2 = A22, A3 = A23),
block3 = list(A1 = A31, A2 = A32, A3 = A33))
p.block <- list(p1 = 3, p2 = 3, p3 = 4)
x11 <- x12 <- x13 <- rep(0, 3)
x21 <- x22 <- x23 <- rep(0, 3)
x31 <- x32 <- x33 <- rep(0, 4)
x0.block <- list(x10 = list(x1 = x11, x2 = x12, x3 = x13),
x20 = list(x1 = x21, x2 = x22, x3 = x23),
x30 = list(x1 = x31, x2 = x32, x3 = x33))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.