| From | Nick Winter <[email protected]> |
| To | [email protected] |
| Subject | Re: st: Automatic mean-centering? |
| Date | Wed, 25 Aug 2004 16:48:45 -0400 |
At 03:34 PM 8/25/2004 -0400, you wrote:
You are probably looking for something more automated or sophisticated, but I usually do something like this:You can avoid generating a new variable here:
foreach var in x x1 x2 x3 x4 x5 x6 x7 x8...x100{
egen temp`var'=mean(`var')
gen c`var'=`var'-temp`var'
}
drop temp*
Sarah
| © Copyright 1996–2025 StataCorp LLC | Terms of use | Privacy | Contact us | What's new | Site index |