Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

oplantalech
Copy link
Contributor

The logic of building the tabular download for OncoPrint assumes each track is a different gene. This causes issues when creating the tabular file for a query with multiple tracks of the same gene, only keeping the alterations of the last track of the gene.

For example, for the query with CDKN2B:MUT and CDKN2B:HOMDEL, when we have HOMDELs as the second track, only HOMDELs are shown in the downloaded tabular file (and no MUTs): https://www.cbioportal.org/results/oncoprint?cancer_study_list=ccle_broad_2019&Z_SCORE_THRESHOLD=2.0&RPPA_SCORE_THRESHOLD=2.0&profileFilter=mutations%2Cstructural_variants%2Ccna&case_set_id=ccle_broad_2019_cnaseq&gene_list=CDKN2B%253AMUT%250ACDKN2B%253AHOMDEL&geneset_list=%20&tab_index=tab_visualize&Action=Submit&show_samples=true

When the same query is with MUT displayed in the second track, and HOMDELs in the first track, then we only see the MUT (and no HOMDELs) in the tabular file: https://www.cbioportal.org/results/oncoprint?cancer_study_list=ccle_broad_2019&Z_SCORE_THRESHOLD=2.0&RPPA_SCORE_THRESHOLD=2.0&profileFilter=mutations%2Cstructural_variants%2Ccna&case_set_id=ccle_broad_2019_cnaseq&gene_list=CDKN2B%253AHOMDEL%250ACDKN2B%253AMUT&geneset_list=%20&tab_index=tab_visualize&Action=Submit&show_samples=true

This PR fixes this issue, combining the alterations that occur in multiple tracks when they belong to the same gene.

@oplantalech oplantalech requested a review from dippindots May 12, 2025 14:22
@dippindots dippindots requested a review from alisman May 12, 2025 16:19
@oplantalech oplantalech requested a review from alisman June 5, 2025 13:03
@alisman alisman force-pushed the fix_oncoprint_tabular_download branch from 90ab3a1 to ad25f66 Compare June 5, 2025 15:25
@alisman
Copy link
Collaborator

alisman commented Jun 5, 2025

@oplantalech i think we should write some unit tests for this. i've used ai code assist for writing unit tests with good results. you could try it.

@oplantalech oplantalech force-pushed the fix_oncoprint_tabular_download branch from 7f7d36c to a349d3a Compare August 1, 2025 13:40
@oplantalech
Copy link
Contributor Author

@alisman Sorry about not getting to this earlier. I've added a test for the case that was failing; if you run the same test without the fix, you can see that the TP53 truncating mutation is not present in the output.

@oplantalech oplantalech requested a review from alisman August 4, 2025 12:58
@dippindots
Copy link
Collaborator

@oplantalech I’ve left a few comments on this pull request, could you take a look when you get a chance? I also noticed that some tests show the data order being updated, which might be related. Could you check if that change was intended? Let me know if you’d like to discuss further.

@oplantalech oplantalech force-pushed the fix_oncoprint_tabular_download branch from 0eb78c3 to febf468 Compare August 11, 2025 09:27
@oplantalech
Copy link
Contributor Author

@dippindots Looks like all the tests pass now. I think I need to rebase, though

@oplantalech oplantalech force-pushed the fix_oncoprint_tabular_download branch from 39f534b to 0a62d7a Compare September 10, 2025 07:40
@alisman alisman merged commit bf9d8bf into master Sep 15, 2025
18 of 20 checks passed
@alisman alisman deleted the fix_oncoprint_tabular_download branch September 15, 2025 19:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants