Reputation: 173
In Jupyter Notebook, I am able to convert a notebook to pdf and HTML using nbconvert. However, there is no way to convert it into .doc(Word Document). Is there a way to convert it to MS Word keeping the same text highlights and table structure?
Upvotes: 17
Views: 67425
Reputation: 29
For me, vertopal worked great doing the following steps:
Upvotes: 1
Reputation: 453
This gives a copy of the notebook that is more faithful to the original notebook than, for example, going via markdown and pandoc, which does not render the notebook perfectly.
You can then carry out any Word operation you like (eg. save as docx, indicate changes using Track Mode TRK, etc, etc).
I have not tried tables. Could someone try using tables with this technique and give feedback?
Upvotes: 1
Reputation: 1363
Use this website https://alldocs.app/convert-jupyter-notebook-to-word-docx
Upload the .ipynb, it works with code, text and pictures
Upvotes: 7
Reputation: 349
The simplest way to convert a jupyter notebook (.ipynb file) to word file (.docx) is using pandoc. First install pandoc, follow instruction here. Once installed, open your terminal to check if its installed correctly by using
pandoc --version
Once you are sure its installed there, use the following line of code in the terminal to convert the jupyter notebook to word file.
pandoc jupyter_file.ipynb -s -o new_word_file.docx
One word of caution, you first need to get into the directory in which your jupyter notebook is, in your command prompt. You can do that by typing the path after writing cd(change directory) in the command prompt. This code will create the word file in the same folder where the Jupyter notebook is.
Upvotes: 21
Reputation: 3790
To get the best result, it needs multi-steps but will get a nice shape as you wish
Download the notebook as a latex file
Then upload this file into overleaf https://www.overleaf.com/project and customize it by splitting the pages as you please. \newpage
Download the pdf file from Overleaf into your local computer.
Convert the downloaded pdf into Docx using either of the following
Upvotes: 6
Reputation: 309
To convert the Jupyter Notebook to Word
Upvotes: 8