Use case example: came here looking for a way to get MultiQC reports into my thesis document, which is a PDF.
I am having trouble converting some MultiQC reports from HTML to PDF format while preserving the files' graphics. I am working on a Red Hat Linux cluster and trying to accomplish this with a Bash script. Currently, I have tried using several versions of wkhtmltopdf to do this, and, although it converts the files, the graphs and charts are not rendered. For example, the charts for where my Sequence Quality Histograms or Per Sequence Quality Scores should be will instead have a gray box with the text "loading..." inside. Has anyone found a tool that works for this?
3 answers
The problem is that MultiQC plots are by default rendered as interactive JavaScript objects. These aren't traditional graphics and tend to not do well with HTML conversion tools such as the one you're trying. MultiQC can render static image plots though, using the option --flat. There's also a template called "simple" (use -t simple) which produces a report with no JavaScript at all.
The --pdf option renders a HTML report using the simple template and then passes this through the pandoc command (see the command here). It's a little flaky as it requires you to install pandoc yourself, which can vary quite a bit between systems. It is something that could potentially be dropped in future versions of MultiQC.
Generally when people ask about PDF conversion I ask "Why?". I'm always curious - what's the use case here?
Phil _(author of MultiQC)_
http://multiqc.info/docs/#pdf-reports
According to their docs it supports output in PDF natively, though you need Pandoc installed.
Otherwise you may be able to convert it yourself with Pandoc.
If you have already generated a regular MultiQC html report, and you are not able to rerun MultiQC again for any reason, you can convert it to pdf using the Opera browser. Save it directly into pdf instead of printing it. (One use case would be if you are asked to actually print at least some of your results.) Surely, if htmldoc / pandoc on the command line works for the conversion, then it is the way to go.
Log in to answer this question.
duplicate of Fastqc Html Report To Pdf (With A Script)