Description Usage Arguments Examples
timix function is a mix model function to solve synchronized time sereis. The effects of synchronization and serial correlation are treated as the random effects. The variance-covariance matrix of random effects are prescribed by the parameters rho and omega.
1 | timix(rho, omega, dat, y, f, r, grp, ftest = F)
|
rho |
parameter for serial correlation |
omega |
parameter for synchronization |
dat |
data for the analysis |
y |
column number of the dependent variable |
f |
column number of the fixed effects |
r |
column number of the random effects |
grp |
column number of the group |
1 2 3 4 5 6 7 8 9 | n_time <- 50
n_grp <- 5
y <- simuOneCol(n_time, n_grp, rho = 0.5, omega = 0.5, mean = 0)
x0 <- rep(1, n_time * n_grp) # Intercept
x1 <- simuOneCol(n_time, n_grp, rho = 0.5, omega = 1, mean = 0)
x2 <- simuOneCol(n_time, n_grp, rho = 0.5, omega = 0, mean = 0)
area <- makeGrp(n_time, n_grp)
dat <- data.frame(y, x0, x1, x2, area)
timix(rho = 0.5, omega = 0.5, dat, y = 1, f = 2:4, r = 2:4, grp = 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.