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

Flash read combination statistics plot is misinformative when -O option is not used. #1173

Closed
mahesh-panchal opened this issue Apr 30, 2020 · 3 comments
Labels
bug: core Bug in the main MultiQC code module: change
Milestone

Comments

@mahesh-panchal
Copy link

mahesh-panchal commented Apr 30, 2020

Hi,

I think the default way of capturing data for the Flash module assumes certain flags are set when running. One example is the Combined innie pairs and Combined outie pairs are only available when -O is used ( I think).

When called like this (nextflow):

flash -t ${task.cpus} -o $sample_name -z $reads 2>&1 | tee ${sample_name}.log

This is the relevant part of the log that's output:

[FLASH]  
[FLASH] Read combination statistics:
[FLASH]     Total pairs:      18836854
[FLASH]     Combined pairs:   18472165
[FLASH]     Uncombined pairs: 364689
[FLASH]     Percent combined: 98.06%
[FLASH]  

which makes the Flash read combination statistics plot look like this:
flash_combo_stats_plot

I think this plot is misleading compared to the stats in the General statistics table.
The hover over text also says that 100% are uncombined, only because the other categories are not there.

@ewels
Copy link
Member

ewels commented Apr 30, 2020

Please can you make a PR to https://github.com/ewels/MultiQC_TestData with a full log file in this mode? And a PR to fix it if you fancy 😉

Thanks!

@ewels ewels added bug: core Bug in the main MultiQC code module: change labels Apr 30, 2020
@ewels ewels added this to the MultiQC v1.9 milestone May 8, 2020
@mahesh-panchal
Copy link
Author

mahesh-panchal commented May 13, 2020

I just saw this error in my multiqc log for this style of flash logs.

[2020-05-13 02:23:01,028] multiqc.modules.flash.flash                        [ERROR  ]  'bool' object has no attribute 'items'
[2020-05-13 02:23:01,030] multiqc.modules.flash.flash                        [DEBUG  ]  Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/multiqc/modules/flash/flash.py", line 49, in __init__
    plot=self.summary_plot(self.flash_data))
  File "/usr/local/lib/python3.8/site-packages/multiqc/modules/flash/flash.py", line 176, in summary_plot
    return bargraph.plot(data, cats, splotconfig)
  File "/usr/local/lib/python3.8/site-packages/multiqc/plots/bargraph.py", line 60, in plot
    for k, v in config.custom_plot_config[pconfig['id']].items():
AttributeError: 'bool' object has no attribute 'items'

@ewels ewels closed this as completed in 2fa1471 May 26, 2020
@ewels
Copy link
Member

ewels commented May 26, 2020

Thanks for reporting this @mahesh-panchal - now resolved:

flash_combo_stats_plot

Unused categories are now hidden and if innie or outie uncombined pairs are not reported but uncombined is, then that is plotted. I think that should handle both use cases.

I wasn't able to reproduce the AttributeError problem or spot anything suspicious from the code for that. If you can find a log file that triggers it so that I can reproduce then please open a new issue for it.

Thanks!

Phil

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug: core Bug in the main MultiQC code module: change
Projects
None yet
Development

No branches or pull requests

2 participants