R/ExportedFuncs.R
bdiagMatrix.Rd
Create a block diagonal matrix
bdiagMatrix(mlist, fill = 0)
a list of matrices
value to fill the non-diagnoal elements
a block diagonal matrix
bdiag in Matrix
bdiag
m1 <- bdiagMatrix(list(matrix(1:4, 2), diag(3))) m2 <- bdiagMatrix(list(matrix(1:4, 2), diag(3)),fill = NA)