Description Usage Arguments Value Author(s) Examples
View source: R/data.helper.functions.r
I have only used it for Leslie matrix modelling. Not sure where else it would be useful.
1 | diags.f(mat, diag.pos = -1)
|
mat |
data matrix |
diag.pos |
the sub-diagonal position, i.e. -1 extract the first lower subdiagonal, 0 is the main diagonal |
the specified diagonal as vector
Daniel Duplisea
1 2 3 4 | data.matrix= matrix(1:100,ncol=10)
diags.f(data.matrix,0)
diags.f(data.matrix,-2)
diags.f(data.matrix,8)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.