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

[BUG] convertAlleleCounts.r returns logR = 0 when no coverage in tumour sample #496

Closed
jherrero opened this issue Mar 11, 2022 · 5 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@jherrero
Copy link

Description of the bug

convertAlleleCounts.r returns a logR or 0 when tumourcounts is 0.

Line 85 aims at catching log(0/0) cases, but in line 73, any log(n/0) or log(0/n) that should return +/- Infinity are changed to NA. As a result cases where there is coverage in normal only or in tumour only end up with an incorrect logR = 0.

Additional context

Note that current version of ASCAT ignores non-finite numbers. As such, returning NA or -Infinity doesn't matter at this time, although -Inf gives ASCAT the option to capture these cases in a future version. Alternatively, convertAlleleCounts.r could add a small delta to both tumour and normal counts to avoid +/- Infinity.

In short, there is no perfect solution, at least for now, but returning logR =0 signals lack of CNA instead of, for instance, homozygous deletion. Keeping these logR as -Infinity/+Infinity or simply NA (as for the BAF) would be preferable.

@jherrero jherrero added the bug Something isn't working label Mar 11, 2022
@FriederikeHanssen
Copy link
Contributor

Thank you for reporting this. Ping @lassefolkersen , not sure if this could still be a problem in the module

@maxulysse
Copy link
Member

We won't be converting allecounts in the coming release if I'm not mistaken since the new ascat can handle bam inputs, so won't be an issue anymore indeed.

@lassefolkersen
Copy link
Contributor

Yes, I think so too @maxulysse - the entire thing have (now) been delegated to internal ASCAT 3.0 functions. First the ascat.prepareHTS function - using the official alleleCounter image (mulled with the official bioconda ASCAT-3.0 image), and then the ascat.loadData function to execute the actual ASCAT functions. I would like to test this, however, @jherrero would you like to help with that? It's basically just a matter of running the same setup that you report, but using the nf-dsl2 module setup in this pull request.

@FriederikeHanssen
Copy link
Contributor

@SusiJo is working on this by adding ASSCAT 3.0 into the pipeline

@FriederikeHanssen
Copy link
Contributor

Closed by #606 , upgrade to ASCAT 3.0 makes this script obsolet, so this should fix the issue.

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

5 participants