Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: -svy: mean - problem with returned matrices

From   Richard Williams <>
Subject   Re: st: -svy: mean - problem with returned matrices
Date   Thu, 31 May 2007 13:38:34 -0500

At 11:38 AM 5/31/2007, Steven Samuels wrote:
Can anyone explain why I get the following error?  How can I access
the elements of the matrix which generates the error?


webuse nhanes2, clear
svy : mean height
ereturn list
matrix list e(V_srs)
di el(e(V_srs),1,1)   //OKAY

matrix list e(b)
di el(e(b),1,1)      //GENERATES ERROR
change the last line to

matrix bmat = e(b)
di el(bmat,1,1)

I'm not sure why you get an error but I generally find it is easier to make a copy of e(b) and to work with it.

Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME: (574)289-5227
EMAIL: Richard.A.Williams.5@ND.Edu

* For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index