Hello together,
I have the following problem. I need to create a non-overlapping event
data set. I have two date variables 1st: "eventdate" which is the
start of the event and 2nd: "postdays", which is the end of the event.
The length of the event is exactly 20 days (which is, of course, the
difference between "eventdate" and "postdays"). If two events overlap
(which happens in trade 1 and 2, in the example below) I only take
the first event and drop the 2nd (trade 2).
How can I do this in Stata? I have about 140000 trades, several
thousands companies etc....
trade companyname name eventdate
postdays
1 Company A Margetts, Rob 14-Feb-03
06-Mar-03
2 Company A Margetts, Rob 17-Feb-03
09-Mar-03
3 Company A Margetts, Rob 14-Nov-03
04-Dec-03
4 Company A Margetts, Rob 14-May-04
03-Jun-04
5 Company A Margetts, Rob 06-Aug-04
26-Aug-04
Many thanks for any help in advance!
Kaspar
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/