Closed subwaystation closed 10 months ago
I could add an option to specify the output format (pdf/png). Separate PNGs... what do you mean by that?
The final output is one PDF with 3 Figures, if I am not mistaken. panacus.pdf In the MultiQC report, we would like to have 3 separate figures, so we would need each of them in its own PNG file.
The option specifying the output format sounds great!
Regarding the separation of figures: Panacus always produces 1 output file from 1 input file. But if you want to have the figures separated, it's super easy to have this done in a subsequent script that utilizes identify
and convert
from ImageMagick.
identify
gives you the dimensions of the image:
identify panacus.png
panacus.png PNG 9000x1800 9000x1800+0+0 8-bit sRGB 690629B 0.000u 0:00.000
convert
:
convert -crop 3000x1800+0+0 panacus.png panacus1.png
convert -crop 3000x1800+3000+0 panacus.png panacus2.png
convert -crop 3000x1800+6000+0 panacus.png panacus3.png
(Also, there is a bug in the plotting script that draws the estimate of the 2nd plot at the wrong position; I just pushed a fix)
Yes, we also thought about ImageMagick. But that would mean more work downstream for us. A new nf-core module, more to maintain, etc. That's why we are wishing for 3 PNGs. If that's not possible, we will have to go for the ImageMagick option.
Everything is negotiable... My coding principles are hanging high enough so that I can limbo below every once in a while. If you're not happy with postprocessing, I'm also accepting pull requests with your solution :)
Please take a look at https://github.com/marschall-lab/panacus/pull/11/files @danydoerr
@subwaystation Thanks! Very helpful, I only have a few requests that I think will improve the usability.
It's now merged. Again, thanks @heringerp!
@heringerp @subwaystation made a minor change for the prefix argument, which is now called 'split_prefix', to associate it more closely with the split option
Hi @danydoerr,
could you please provide an option to output the plots in separate PNG files? @heringerp is working on making panacus a module for nf-core. However, in order for the results to be integrated into a MultiQC report, we need PNGs. PDFs are not supported.
Thanks!
Best, Simon