View source: R/ExportedFuncs.R
bdiagMatrix | R Documentation |
Create a block diagonal matrix
bdiagMatrix(mlist, fill = 0)
mlist |
a list of matrices |
fill |
value to fill the non-diagnoal elements |
a block diagonal matrix
bdiag
in Matrix
m1 <- bdiagMatrix(list(matrix(1:4, 2), diag(3)))
m2 <- bdiagMatrix(list(matrix(1:4, 2), diag(3)),fill = NA)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.