Here I have some codes generating a matrix like this:
N = 200
T = 10
mu_0 <- matrix(diag(1, T))
dim(mu_0) <- c(T,T)
mu_t_0 <- matrix(rep(t(mu_0), N), ncol = T, byrow = TRUE)
And generally the result looks like this
V1 V2 V3 V4 V5 V6 V7 V8 V9 V10
1 1 0 0 0 0 0 0 0 0 0
2 0 1 0 0 0 0 0 0 0 0
3 0 0 1 0 0 0 0 0 0 0
4 0 0 0 1 0 0 0 0 0 0
5 0 0 0 0 1 0 0 0 0 0
6 0 0 0 0 0 1 0 0 0 0
7 0 0 0 0 0 0 1 0 0 0
8 0 0 0 0 0 0 0 1 0 0
9 0 0 0 0 0 0 0 0 1 0
10 0 0 0 0 0 0 0 0 0 1
11 1 0 0 0 0 0 0 0 0 0
12 0 1 0 0 0 0 0 0 0 0
13 0 0 1 0 0 0 0 0 0 0
14 0 0 0 1 0 0 0 0 0 0
15 0 0 0 0 1 0 0 0 0 0
16 0 0 0 0 0 1 0 0 0 0
17 0 0 0 0 0 0 1 0 0 0
18 0 0 0 0 0 0 0 1 0 0
19 0 0 0 0 0 0 0 0 1 0
20 0 0 0 0 0 0 0 0 0 1
...
Now for later calculation I want to split this large matrix into different small matrices like this:
Matrix One:
1
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
...
Matrix Two:
0
1
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
...
I tried the split function but I cannot get what I want. Are there any solutions?