Description Usage Arguments Value Examples
construct the autocorrelation matrix for a given case, Sigma_i. Original author: Pustejovsky from scdhlm package.
1  | AR1_matrix(phi, rho, times)
 | 
phi | 
 1-st order autocorrelation  | 
rho | 
 intraclass variation, i.e. the ratio of intra-person variance to total variance, i.e. (tau^2 / (tau^2 + sigma^2))  | 
times | 
 a sequence 1:N_i for a given case  | 
a (N_i, N_i)-dimensional (square) matrix
1  | Sigma_1 <- AR1_matrix(sim_df[sim_df$case == 1, "treatment"], k = 2)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.