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

Conpair concordance file not found by MultiQC #1851

Closed
ehenrion opened this issue Jan 31, 2023 · 6 comments
Closed

Conpair concordance file not found by MultiQC #1851

ehenrion opened this issue Jan 31, 2023 · 6 comments
Labels
bug: module Bug in a MultiQC module

Comments

@ehenrion
Copy link
Contributor

ehenrion commented Jan 31, 2023

Description of bug

Depending on how the Conpair script verify_concordance.py is called (with or without the --outfile parameter in command line), the output is slightly different (see here at lines 86 to 97)

The Conpair module of MultiQC seems to only cover the case when --outfile is specified in the command line :

conpair/concordance:
  contents: "markers (coverage per marker threshold : "
  num_lines: 3

Indeed, when not using the --outfile in command line and redirecting the output into a file instead, the pattern specified in contents does not match anymore. As you can see in the example file I sent, there is no space character between threshold and the : :

0.999
Based on 3954/7353 markers (coverage per marker threshold: 10 reads)
Minimum mappinq quality: 10
Minimum base quality: 20

Unfortunately I am dealing with data that have been produced using both ways... This results in some reports showing the concordance metrics and some other reports which don't show the concordance...

I have made the following change in my search_patterns.yaml so that the concordance file can be found :

conpair/concordance:
  # contents: "markers (coverage per marker threshold : "
  contents_re: '.*markers \(coverage per marker threshold\s?: .*'
  num_lines: 3

Now I'm wondering if this was the way to go or if there are other ways to change search patterns than having to change the "core" of multiqc, using command line parameters maybe ?

File that triggers the error

concordance.zip

MultiQC Error log

$ multiqc -f   metrics/MoHQ-CM-3-42-158703-1DT.concordance.tsv       -n ~/test/multiqc/test 


  /// MultiQC 🔍 | v1.14

|           multiqc | Search path : /lustre03/project/6007512/C3G/projects/MOH_PROCESSING/MAIN/metrics/MoHQ-CM-3-42-158703-1DT.concordance.tsv
|         searching | ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100% 1/1  
|           multiqc | No analysis results found. Cleaning up..
|           multiqc | MultiQC complete
@ewels
Copy link
Member

ewels commented Jan 31, 2023

Now I'm wondering if this was the way to go or if there are other ways to change search patterns than having to change the "core" of multiqc, using command line parameters maybe ?

If this minor change fixes it and works for both situations, then please submit a pull-request with it to fix it for everyone 👍🏻 (or I can when I get a chance, currently on paternity leave though).

Short term you can overwrite these search patterns for yourself without touching the MultiQC core, yes. Just use a config file. See search pattern docs.

Phil

@ewels ewels added the bug: module Bug in a MultiQC module label Feb 1, 2023
@ehenrion
Copy link
Contributor Author

ehenrion commented Feb 1, 2023

Hi Phil,

Thanks for your time and please take care of yourself during your paternity leave ! :)

Thanks for the search pattern trick, I knew I was missing something ;)

I will submit a pull-request.
The changes are deeper than I first expected.
I have to modify the conpair module as well because, just as for the search pattern, the regular expressions currently used in the module don't cover the cases I mentioned above i.e. no match with the concordance output of Conpair when not using --outfile in the Conpair command.

Thanks again for your support !

Ed

@ehenrion
Copy link
Contributor Author

ehenrion commented Feb 1, 2023

It seems I can't create a new branch... I fall into a "Permission denied" issue...
Do I have to register somewhere ?

@ewels
Copy link
Member

ewels commented Feb 1, 2023

You need to fork the repository to your own account. Then you can open a pull-request back to this repository from there.

See the GitHub docs for more 🙂

@ehenrion
Copy link
Contributor Author

ehenrion commented Feb 2, 2023

Oh I feel dumb... 😅

PR created : #1855

@vladsavelyev
Copy link
Member

Fixed with #1855

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

No branches or pull requests

3 participants