| |
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
RE: Re: st: From spell to person-month file
I think you are referring to
y
when you should be referring to
`y'
Nick
[email protected]
A. Manzoni
If I write this command,
**
foreach x in b c d e f g h i j k l m n o p q r s t u {
foreach y of varlist bp45 cp36 dp34 ep34 fp27g gp30g zp331 hp32g ip32g jp32g
kp44 lp42 mp40 np3401 op3401 pp3701 qp3501 rp3901 sp3901 tp6501 up3601 {
use "D:\Project\Data_anal\GSOEP\My analyses\persm_job.dta", clear
sort persnr month
merge persnr month using "D:\Project\Data_anal\GSOEP\My
analyses\temp\\`x'p_int.dta", keep (y)
ren y contr_`x'
drop _merge
save "D:\Project\Data_anal\flex\contract_gsoep.dta", replace
}
}
**
it doesn't work because it can't find the y variable in the using data
file. My y infact is in the using data faile.
How can I write this command?
Thanks,
Anna
*
* 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/
--------------------------------------------------------------------------------
Next Article (by Date): Re: st: SVY and risk ratio
=?ISO-8859-1?Q?Ron=E1n_Conroy?=
Previous Article (by Date): Re: Re: st: From spell to person-month file
n j cox
Top of Thread: Re: Re: st: From spell to person-month file n j cox
Articles sorted by: [Date] [Author] [Subject]
--------------------------------------------------------------------------------
Go to Harvard School of Public Health LWGate Home Page.
*
* 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/