Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Making permutations of dyads


From   Douglas Levy <[email protected]>
To   [email protected]
Subject   st: Making permutations of dyads
Date   Thu, 19 Dec 2013 14:29:32 -0500

Hi All,
I'm trying to create a dataset of all paired permutations of subject
IDs within time blocks or alternatively time bands. My data look like
this:
ID    time  5m_block
1     8:00  1
2     8:02  1
3     8:02  1
4     8:04  1
5     8:06  2
6     8:07  2
7     8:09  2

For 5 minute time blocks,  I'd want to output a dataset that looks like this:
Dyad
12
13
14
21
23
24
31
32
34
56
57
65
67
75
76

For 5m intervals, I'd want:
Dyad
12
13
14
21
23
24
25
31
32
34
35
41
42
43
45
46
52
53
54
56
57
64
65
67
75
76

Thanks for any/all suggestions!
-Doug
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index