ang_smiles
New Member
Hello! I have a complex issue I'm trying to resolve. I know it's going to use transpose, but I also need to simplify my data...
I'd like to turn something like this (there are three different samples, and they each have the same five loci. The alleles may or may not be different):
into this (note, I don't need to copy the headers, just the data):
I've been searching for hours on google and on various forums and threads, but I the only thing I could find was kind of the "opposite" of my situation (i.e. going from B -> A rather than I want A -> B)
I'd like to turn something like this (there are three different samples, and they each have the same five loci. The alleles may or may not be different):
Code:
Sample Locus Alleles
a 1 AA
a 2 B
a 3 C
a 4 DD
a 5 EEE
b 1 F
b 2 GG
b 3 H
b 4 I
b 5 JJ
c 1 K
c 2 LLL
c 3 MM
c 4 N
c 5 OO
into this (note, I don't need to copy the headers, just the data):
Code:
Sample 1 2 3 4 5
a AA B C DD EEE
b F GG H I JJ
c K LLL MM N OO
I've been searching for hours on google and on various forums and threads, but I the only thing I could find was kind of the "opposite" of my situation (i.e. going from B -> A rather than I want A -> B)