Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: extracting the variable name from e(wtype) container after regrress


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: extracting the variable name from e(wtype) container after regrress
Date   Thu, 10 Nov 2005 18:50:30 -0000

Your title says e(wtype), your post says e(wexp). 

Try 

tokenize "`e(wexp)'", parse("=") 
local wexp "`2'"

_or_ 

 local wexp "`: word 2 of `e(wexp)''"

and then 

di "`wexp'"

Nick 
[email protected] 

Wolfgang Langer
 
> I have written a small program to calculate the 
> goodness-of-fit-chi2-test after estimating a WLS -regression 
> modell for 
> tabulated data (GSK-approach). How can I extract the varname from the 
> e(wexp) container to use it in my program?  Typing "dis  
> e(wexp)" I get 
> only the  expression "=var name of  weighting variable" but  not the  
> varnme itself. I need this to formulate my program gofchi2 
> mor generally.

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



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