Hi All,
I would like to replace the diagonal elements of the matrix (ZZ below) with the values that are in the Z matrix (which are in a row).
I saw in the help file for mata there appears some way to use _diag() for this, but I don't know mata, and Stata keeps shutting down when I try to apply it...
Thanks in advance!
Ariel
I would like to replace the diagonal elements of the matrix (ZZ below) with the values that are in the Z matrix (which are in a row).
Code:
matrix Z = (3883, 4478, 4963) matrix ZZ = (1520, 0, 0 \ 0, 1512, 0 \ 0, 0, 1772)
Thanks in advance!
Ariel
Comment