Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ivar_variants_to_vcf.py collapses low quality ivar variant with high quality variant #337

Open
Rohit-Satyam opened this issue Nov 6, 2022 · 4 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@Rohit-Satyam
Copy link

Rohit-Satyam commented Nov 6, 2022

Description of the bug

I noticed that ivar_variants_to_vcf.py is not behaving correctly. I was testing the difference between the phasing features of your ivar_variants_to_vcf.py and phasing.py, provided by COVIGATOR and it turns out that ivar_variants_to_vcf.py collapses bad quality variant with good quality variant
Eg:

MN908947.3	24129	A	G	30	29	36	1	1	37	0.0322581	31	0.508197	FALSE	CDS:ENSSASP00005000004	AAC	N	AGC	S
MN908947.3	24130	C	A	0	0	0	33	32	36	1	33	2.7703E-19	TRUE	CDS:ENSSASP00005000004	AAC	N	AAA	K

The A>G mutation at position 24129 is present in just 1. Therefore no matter that low quality variant call lie within same codon as high quality, they should be kept separate and only the high-quality calls must be collapsed. The current behaviour of your script is as follows:

MN908947.3	24129	.	AC	GA	.	ft	DP=31	GT:REF_DP:REF_RV:REF_QUAL:ALT_DP:ALT_RV:ALT_QUAL:ALT_FREQ	1:30:29:36:1:1:37:0.0322581	
MN908947.3	24256	.	T	C	.	ft	DP=33	GT:REF_DP:REF_RV:REF_QUAL:ALT_DP:ALT_RV:ALT_QUAL:ALT_FREQ	1:32:0:36:1:0:37:0.030303	

However it should be

MN908947.3	24129	.	A	G
MN908947.3	24130	.	C	A

Also, it is quite misleading to assign AC>GA with following tags of high quality variant DP=31 GT:REF_DP:REF_RV:REF_QUAL:ALT_DP:ALT_RV:ALT_QUAL:ALT_FREQ 1:30:29:36:1:1:37:0.0322581

image

Command used and terminal output

No response

Relevant files

No response

System information

No response

@Rohit-Satyam Rohit-Satyam added the bug Something isn't working label Nov 6, 2022
@Rohit-Satyam
Copy link
Author

@mattheww95 @saramonzon Any thoughts here?

@drpatelh drpatelh added this to the 2.6 milestone Mar 5, 2023
@drpatelh
Copy link
Member

@Rohit-Satyam presumably this issue is unrelated to #321 (comment) ? @saramonzon is this something we can fix in future releases?

@saramonzon
Copy link
Contributor

saramonzon commented Mar 13, 2023

Yes this is unrelated to the #321 fixes, we can totally fix it in the next releases, i will add it to the to do list :) Thanks for the tip!

@drpatelh
Copy link
Member

Cool. Will move to the next milestone. Thanks @saramonzon !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants