Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Cumulative Sum by groups


From   "Alexander Nervedi" <[email protected]>
To   [email protected]
Subject   st: Cumulative Sum by groups
Date   Fri, 22 Apr 2005 14:13:34 +0000

Hi

I am looking to implement a group level cumulative sum that starts counting backwards. Any suggestions on how to go about this would be really useful

data example:
ID year num cusum
1 90 1 2
1 91 1 1
2 90 1 4
2 91 1 3
2 92 1 2
2 93 1 1
3 90 1 1
4 90 1 2
4 90 1 1
...

I have variables ID year and num, and am trying to create cusum

thanks

-AN

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

*
* 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/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index