Hello statalist members i have the variance covariance matrix of BG that is a matrix that combines two vectors created as follows:
mat BG=G,B
mat li BG
// var-covar matrix
mat var_cov=get(VCE)
mat li var_cov
I have a problem when i try to calculate the inverse of var_cov matrix since when i input:
mata: inv_cov=cholinv("var_cov")
it pops out error 3251: cholinv(): 3251 <tmp> [1,1] found where real or complex required
<istmt>: - function returned error
My values should be all real and i don't understand why it tells me that they are not.
Anybody has an answer?
Would really appreciate your help
Best
Donald
mat BG=G,B
mat li BG
// var-covar matrix
mat var_cov=get(VCE)
mat li var_cov
I have a problem when i try to calculate the inverse of var_cov matrix since when i input:
mata: inv_cov=cholinv("var_cov")
it pops out error 3251: cholinv(): 3251 <tmp> [1,1] found where real or complex required
<istmt>: - function returned error
My values should be all real and i don't understand why it tells me that they are not.
Anybody has an answer?
Would really appreciate your help
Best
Donald
Comment