Hi,
I'm struggling with a data manipulation problem: I have a dataset with list
of observations on a string variable and want to create pairwise
combinations. My dataset looks like this:
country1
A
B
C
I need the possible combinations so that the new dataset looks like
country1 country2
A B
A C
C B
I could take the same list in two different datasets and then use the
command "cross", but that gives me 3! combinations:
AB AC BA BC CA CB
For my purposes, AB and BA are identical. How do I create the list?
Cheers,
Mark
Mark Manger
University of British Columbia
[email protected]
*
* 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/