You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code was handling the merging in a simplistic way, SNPs vs everything else.
As pointed by #2084, it also would not merge indels with `-m +indels`, only
with `-m +both` or `-m +any`.
Also splitting by type was not functioning properly due to an error where
two incompatible bitmasks were used together (e.g. COLLAPSE_SNPS vs VCF_SNP)
This is now fixed and improved, the new behavior is as follows:
- multiallelic sites with containing SNPs but not indels are split
with `-m -snps` but not with `-m -indels`, and analogously for
indels.
- multiallelic sites containing both SNPs and indels are split when
any of the following is given: `-m -snps`, `-m -indels`, `-m both`,
`-m any`
- merging with `-m +snps` and `-m +indels` should work as expected
in case of pure SNP or indel sites. When the input sites contain
a mixture of types (e.g. SNP + indel), such sites will not be merged.
- merging with `-m +both` will merge together not just SNPs with SNPs
and indels with indels, but also "other types" with "other types".
Note: this could be improved by providing the user with a way to
fine-tune the desired behaviour, for example something like
-m +snps+mnps,indels
to merge SNPs with MNPs together and indels together. This would
not be too difficult to add, but would complicate the user interface.
Another improvement would be to make it possible to split multiallelic
sites containing both SNPs and indels so that
a) two mutliallelic sites are emitted, one with SNPs only and one with
indels only
b) as above, but one is transformed into multiple biallelic sites and
one multiallelic site
This could be further improved (and complicated) by considering other
variant types.
Resolves#2084
Copy file name to clipboardExpand all lines: test/test.pl
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -298,6 +298,12 @@
298
298
run_test(\&test_vcf_norm,$opts,in=>'norm.right-align',fai=>'norm.right-align',out=>'norm.right-align.2.out',args=>'--old-rec-tag ORI -g {PATH}/norm.right-align.gff');
299
299
run_test(\&test_vcf_norm,$opts,in=>'norm.atom-split-norm',fai=>'norm.atom-split-norm',out=>'norm.atom-split-norm.1.out',args=>'--old-rec-tag ORI -a -m -any');
0 commit comments