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
When read depth is very high, ivar variants outputs depth in scientific notation. variants_long_table reports only the part of the number before the decimal, resulting in inaccurate depths and allele frequencies.
Thanks for reporting @wutron ! Fancy creating a PR with a fix for this issue and #369 ? Your timing is great because I am planning to release tomorrow.
Invited you to become a member of the nf-core Github org too. Thanks for providing the fix! Fancy reviewing and approving the PR? You will be able to test dev once that PR is merged to confirm everything is ok.
nextflow pull nf-core/viralrecon -r dev
nextflow run nf-core/viralrecon <YOUR_PARAMETERS> -r dev
Description of the bug
When read depth is very high,
ivar variants
outputs depth in scientific notation.variants_long_table
reports only the part of the number before the decimal, resulting in inaccurate depths and allele frequencies.I believe the issue can be resolved by modifying https://github.com/nf-core/viralrecon/blob/master/bin/ivar_variants_to_vcf.py#L123 to
INFO = f"DP={int(float(line[11]))}"
to always report depth in vcf as an integer.$ grep 'e+' out/variants/ivar/ww.tsv
$ awk -F, '$10>1' out/variants/ivar/variants_long_table.csv
Command used and terminal output
No response
Relevant files
No response
System information
Nextflow version: 19.01.0.5050
Hardware: Cloud VM
Executor: local
Container engine: Docker
OS: Linux
Version of nf-core/viralrecon: 2.5
The text was updated successfully, but these errors were encountered: