oxfordmmm/gumpy

gumpy doesn't check that the `REF` field in a vcf file matches what it is the `Genome` object when adding

Opened this issue · 1 comments

I can change the base in the REF field and gumpy doesn't complain. Since these are all the forward strand it should be easy to assert that the specified REF base from a vcf file matches a Genome object when you do

sample = reference + vcf

There will be a performance cost but I think it is worth it. Would automatically stop you trying to add two vcfs in succession both of which mutate the same base since after the first vcf it would not longer match REF.

Also worth checking that REF != ALT in a vcf file --> in my testing files I managed to have an incorrect REF with a different ALT but the ALT matched the real REF so gumpy produced no output which confused me for a while! These two rules would prevent that.