Skip to content

Re-sort list of vectors

1 message · Liaw, Andy

#
If all vectors in the list have the same length, why not use a matrix?  Then
you'd just transpose the matrix if you need to.  If you really have to have
it as a list, here's one possibility:
$"1"
a b c 
1 2 3 

$"2"
a b c 
4 5 6
$V1
[1] 1 4

$V2
[1] 2 5

$V3
[1] 3 6

Andy