On Mon, Nov 08, 2021 at 04:00:45PM +0000, Thomas Juettemann wrote:
> hopefully a few very simple questions from a newb in the area:
> From playing around, it seems that this is the sorting order:
> 
> 1. Chromosome
> 2. Position
> 3. Reference
> 4. Alternative Allele

I took a look at the code and found this:

https://github.com/samtools/bcftools/blob/develop/vcfsort.c#L95-L117

It does indeed appear to match your observations and it doesn't look
to have anything else in there except for some logic where the number
of alleles differs but are otherwise identical up to that point.
(Which arguably is the same as saying sorted by
ref,alt[,alt]... anyway.

James

-- 
James Bonfield (j...@sanger.ac.uk)
The Sanger Institute, Hinxton, Cambs, CB10 1SA


-- 
 The Wellcome Sanger Institute is operated by Genome Research 
 Limited, a charity registered in England with number 1021457 and a 
 company registered in England with number 2742969, whose registered 
 office is 215 Euston Road, London, NW1 2BE. 


_______________________________________________
Samtools-help mailing list
Samtools-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/samtools-help

Reply via email to