Hello,

having a data frame like test with pairs of characters I would like to
create chains. For instance from the pairs A/B and B/I you get the vector A
B I. It is like jumping from one pair to the next related pair. So for my
example test you should get:
A B F G H I
C F I K
D L M N O P


> test
   V1 V2
1   A  B
2   A  F
3   A  G
4   A  H
5   B  F
6   B  I
7   C  F
8   C  I
9   C  K
10  D  L
11  D  M
12  D  N
13  L  O
14  L  P

Thanks
Hermann

> dput (test)
structure(list(V1 = c("A", "A", "A", "A", "B", "B", "C", "C",
"C", "D", "D", "D", "L", "L"), V2 = c("B", "F", "G", "H", "F",
"I", "F", "I", "K", "L", "M", "N", "O", "P")), .Names = c("V1",
"V2"), row.names = c(NA, -14L), class = "data.frame")
>

	[[alternative HTML version deleted]]

