Hello,
for each chromosome, I have a multisample VCF containing the same set of samples. However, the order of the sample columns varies among the VCFs.
For example:
VCF file 1:
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT 14 11 13 12 3 6 10 7 9 5 8 2 4 1
VCF file 2:
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT 5 9 11 13 2 7 12 6 10 14 4 3 8 1
I'd like to merge them so that the samples with the same ID are concatenated. However, since the sample order differs, I can't use bcftools concat...
Any suggestions of how I could either
- change the order of the samples in every multisample-vcf so that I can use bcftools
- use a different tool to concatenate the VCF files
Cheers