MCMCglmm (version 2.29)

list2bdiag: Forms the direct sum from a list of matrices

Description

Forms a block-diagonal matrix from a list of matrices

Usage

list2bdiag(x)

Arguments

x

list of square matrices

Value

matrix

Examples

Run this code
# NOT RUN {
M<-list(rIW(diag(3), 10), rIW(diag(2), 10))
list2bdiag(M)
# }

Run the code above in your browser using DataCamp Workspace