I am a structural engineer and I need to produce calculations which basically look like a report with a mix of text, tables, math expressions etc... These calculations are highly repetitive so when I design a joist for instance, apart from the numbers, the output is the same.
At the moment, I tend to do the calcs and then write them down either by hand or in an open office document. To do some of the repetitive calculations I sometimes use the Ipython notebook together with some python modules I've written.
Now the really neat thing would be to use my calcs in the Ipytrhon notebook directly to produce the output. The output could be a pdf document.
Thus seeing nbconvert appear really got me interested, I still need to do some work on understanding the templating bit.
So to get there, I need to :
- Make my module functions output some latex - I should be OK with this
Format the nbconvert output as I want. I found this Writing an IPython notebook to HTML or PDF with Table Of Content and this Suppress code in NBConvert? IPython Can anybody point toward more comprehensive tutorials? Is there a way selectively show or hide some blocks of codes from the input? Something like this in the input cell would be fantastic :
/hide Boring code //hide Interesting python code I want to show
Find a way to insert pdf pages Sometimes I will need to insert other stuff such as drawing or even something handwritten and it would be nice to be able to write a small function like insertmypdf(pathtomy/document.pdf). So that when I execute nbconvert it automatically inserts the pages.
Am I dreaming? If you could point me in the right direction I will be grateful. Ideally all the time I spend retyping stuff I've calculated before could be replaced by a
ipython nbconvert --to=latex --template=latex_template.tplx --post=pdf file.ipynb