polio-nanopore / piranha

GNU General Public License v3.0
16 stars 4 forks source link

Insertion and Deletion calls in variants.csv error parse_variant_file() #117

Open DarianHole opened 1 year ago

DarianHole commented 1 year ago

Hi everyone,

We have a spot where some non-polio-ev are getting insertion and deletion calls in variants.csv which exits report generation.

Ex. barcode reference variant_count variants
barcode03 CoxsackievirusB2_KX499536 43 ...132:CT;133:del3;144:CG;...
barcode03 CoxsackievirusB5_MF973166 51 ...116:TG;122:ins6;128:CG;...

This fails the parse_variant_file() function here as it is not a snp with a str length of 2 as is expected.

I'm not sure how you wish to go about handling indels, whether that be just skipping them or handling them some other way so I've just created this issue instead of making a PR to skip these sites

Best, Darian

aineniamh commented 1 year ago

Hi Darien, thanks for flagging this! I'll have a look into this properly in the morning and hopefully can push a fix before the weekend!

DarianHole commented 1 year ago

Yeah no worries! I did a quick fix to it for the moment just checking that the snp string length was 2 characters and if not skipping it

aineniamh commented 1 year ago

Okay, I've implemented something similar now that bypasses the cooccurance plot if it's an indel. I'll have to think about how to properly do this for the coocurrance stuff, but this at least fixes it on the main for the moment! https://github.com/polio-nanopore/piranha/pull/118/files

Thanks for flagging!