How to convert IPython notebooks to PDF and HTML?

Configurare noua (How To)

Situatie

Sometimes according to our necessity, we would want to share or convert the Jupyter notebook to HTML or pdf format. Our Jupiter Notebooks can be easily converted to PDF and HTML files. You may access your notebook as a PDF with only a few simple steps.

Solutie

Pasi de urmat

Open Jupiter notebook in the browser, our menu bar of the Jupyter notebook looks like this:

The following packages must be downloaded, we can download them via the Jupyter notebook itself by using this command:

!pip install -U notebook-as-pdf
!pyppeteer-install

To convert the python notebook to pdf or HTML we’ve to follow this path:

To convert into HTML file’

file ->  Download as -> HTMl(.html)

To convert into a pdf file.file ->  Download as -> PDF via HTML(.pdf) or PDF via pyppeteer(.html)

How to convert IPython notebooks to PDF and HTML?

The converted PDF file:

How to convert IPython notebooks to PDF and HTML?

The converted HTML file:

How to convert IPython notebooks to PDF and HTML?

Tip solutie

Permanent

Voteaza

(12 din 19 persoane apreciaza acest articol)

Despre Autor

Leave A Comment?