Ramani Gunatilaka writes (in part):
> global basefactors = "ln_pcy02 chgln_pcy ln_pcy02_sqd age agesq edyrs
> male single divorced widowed ethmin cpmem unempld r_health workhrs
> finassets hhdebt Anhui Chongqing Gansu Guangdong Guangxi Guizhou Hebei
> Henan Hubei Hunan Jiangsu Jiangxi Jilin Liaoning Shaanxi Shandong
> Shanxi Sicuan Xinjiang Yunnan Zhejiang" /*independent variables in
> standard equation*/
> global m: word count $basefactors /*number of independent variables*/
>
> - foreach x of local sec{
> - use `fname`x'', clear
> = use c:\CHINA\uricevar02, clear
> - keep happy $basefactors
> = keep happy ln_pcy02 chgln_pcy ln_pcy02_sqd age agesq edyrs male
> single divorced widowed ethmin cpmem
> > unempld r_health workhrs finassets hhdebt Anhui Chongqing
> Gansu Guangdong Guangxi Guizhou Hebei Henan
> > Hubei Hunan Jiangsu Jiangxi Jilin Liaoning Shaanxi Sh
> Sh ambiguous abbreviation
> *****************
> Can someone please help? I'd be very grateful.
It stopped where basefactors ends... The last variable it found was "Sh"
because you used the = sign, which limits the # of characters. And "Sh"
is ambiguous.
Do it as
. global basefactors "ln_pcy02 chgln_pcy ..."
and it should work.
-----------------------------------------
CONFIDENTIALITY NOTE: This e-mail message, including any attachment(s),
contains information that may be confidential, protected by the
attorney-client or other legal privileges, and/or proprietary non-
public information. If you are not an intended recipient of this
message or an authorized assistant to an intended recipient, please
notify the sender by replying to this message and then delete it from
your system. Use, dissemination, distribution, or reproduction of this
message and/or any of its attachments (if any) by unintended recipients
is not authorized and may be unlawful.
*
* 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/