I'm sure this is an easier task than I'm making it out
to be but I'm trying to create a cumulative tally of a
binary variable. To illustrate, my data set has the
variable 'X' and I'd like to create the 'sumX'
variable: 
'X' 'sumX'
 0    0
 1    1
 1    2
 1    3
 0    3
 1    4
I've tried writing a simple macro but can't get the
thing to work. Any suggestions?
Thanks,
Jon Schwabish
__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
*
*   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/