Hi all,
Can someone please help me figure out why the first -levelsof- statement,
below, isn't producing anything? The output from the -di- statement leads me
to believe that the -inlist- portion of the last statement should give me what
I want, but it clearly does not. As you can see, if I specify the arguments of
-inlist- directly, I get the result I want.
Thank you,
Danielle Ferry
. global regOnlyVars2 `" "corr_ue", "vol_ue" "';
. di `"$regOnlyVars2"';
"corr_ue", "vol_ue"
. levelsof indepvar
> if inlist(indepvar2, `"$regOnlyVars2"'),
> local(indepvars) cl;
. levelsof indepvar
> if inlist(indepvar2, "corr_ue", "vol_ue"),
> local(indepvars) cl;
L2.corr_ue L3D.vol_ue
--
National Bureau of Economic Research <http://www.nber.org>
*
* 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/