duplicationMatrix {psychonetrics} | R Documentation |
Model matrices used in derivatives
Description
These matrices are used in the analytic gradients
Usage
duplicationMatrix(n, diag = TRUE)
eliminationMatrix(n, diag = TRUE)
diagonalizationMatrix(n)
Arguments
n |
Number of rows and columns in the original matrix |
diag |
Logical indicating if the diagonal should be included (set to FALSE for derivative of vech(x)) |
Value
A sparse matrix
Author(s)
Sacha Epskamp
Examples
# Duplication matrix for 10 variables:
duplicationMatrix(10)
# Elimination matrix for 10 variables:
eliminationMatrix(10)
# Diagonailzation matrix for 10 variables:
diagonalizationMatrix(10)
[Package psychonetrics version 0.13 Index]