Hey,

I found the following code in this forum to get the pseudo R² for imputed data:

Code:
local rhs "armg2 armg3 tbsaburn20 tbsaburn21"
noi mi estimate, or saving(miest, replace): logistic hodc `rhs', vce(cluster site)
qui mi query
local M=r(M)
scalar r2=0
scalar cstat=0
qui mi xeq 1/`M': logistic hodc `rhs'; scalar r2=r2+e(r2_p); lroc, nog; scalar cstat=cstat+r(area)
scalar r2=r2/`M'
scalar cstat=cstat/`M'
noi di "Pseudo R=squared over imputed data = " r2
noi di "C statistic over imputed data = " cstat
I have adapted the code for my needs:

Code:
local rhs "geschl_n alter_n ethnieend2 schform sozhilf_n selcon bsiagg emp hiesel sozdep eltgew herumf rexnied rexmut rexvat rexle rexfr reakmut_pos reakvat_pos reakle_pos reakfr_pos aus_mit"
noi mi estimate, or saving(miest, replace): meqrlogit taetaus `rhs', or || klcode: ,
qui mi query
local M=r(M)
scalar r2=0
scalar cstat=0
qui mi xeq 1/`M': meqrlogit taetaus `rhs', or || klcode: ,; scalar r2=r2+e(r2_p); lroc, nog; scalar cstat=cstat+r(area)
scalar r2=r2/`M'
scalar cstat=cstat/`M'
noi di "Pseudo R=squared over imputed data = " r2
noi di "C statistic over imputed data = " cstat
However, after the "qui mi xeq" command I get the error message "Invalid numlist r(121);". Do you have any idea what I could have done wrong?

Thanks in advance,
Yvonne