I would like to create groups of observations with at least 2 products
invented within 365 days (not a civil year), by firm and industry code.
obs; Firm; ic; date
1; 1; A; 31 dec 02
2; 1; A; 2 Apr 03
3; 1; A; 12 dec 03
4; 1; A; 5 jan 04
5; 1; A; 4 may 04
6; 1; B; 4 may 04
7; 2; A; 1 jan 01
.
.
.
In this example, observations 1 to 3 and 4 to 5 would correspond to a
"group", as the products are invented by the same firm, in the same industry
code within 365 days. The groups have to be "successive", and not
"overlapping".
Thanks for your help,
Andr�