| Date: | Sat, 3 Feb 2007 08:59:32 -0500 |
| Reply-To: | Mayukh Dass <mayukh.dass@GMAIL.COM> |
| Sender: | "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> |
| From: | Mayukh Dass <mayukh.dass@GMAIL.COM> |
| Subject: | Creating dyadic relations with time - more clarifications |
| Content-Type: | text/plain; charset=ISO-8859-1; format=flowed |
Hi,
I may have failed to explain the problem correctly in my last posting. I
apologize for it. Let me try once again.
Entry time difference between companies are calculated between company1 (who
joined first) and company2 (who joined second)
If the input was like the following:
Region Company Time of Entry
1 1 0.23
1 2 0.50
1 1 0.55
1 2 0.65
1 3 0.90
2 1 0.10
2 5 0.65
2 1 0.70
2 2 0.77
the desired output is:
Company1 Company2 Time Difference
1 1 0
1 2 =[(
0.50-0.23)+(0.65-0.55)+(0.77-0.70)]/3
1 3 =[(
0.90-0.55)]
For company1, a new entry will time will be when others entry will be
counted.
In my earlier example, if there was another entry of company =2 in the
region=1 after the second entry of company=1, then we would have considered
the the entry time difference between the second entries of company=1,2. If
the there was no second entry of company=1, we would have considered time
difference between the entry of company=1 and two entries of company=2 while
computing average entry time difference between company1=1 and company2=2.
Hope this clears the problem further.
Thanks in advance for your help.
Regard,
Mayukh
|