Now Serving: Full-Text Sampler in IPython Notebook Format
miningthesocialweb.com
miningthesocialweb.com
We've cross a few authors that were writing books for O’Reilly with IPython Notebooks in the last few month and we have plan to help convert those to (and from) many format. We would be extremely happy to work with people from O'Reilly to simplify the conversion process.
We also have plan to integrate with publication in academic world (see https://github.com/ipython/ipython/issues/4119) but we really need more people involved than the few of us (Core Team).
Even if IPython seem like a big complicated project, moving forward in area like document conversion is not that hard, but just needs lots of eyes and tester to catch all cases.
As for people wanting to convert notebook to other format than those currently supported, it is perfectly possible using nbconvert with template. We can spit the TeX that is just between begin/end document so you can include in your preferred dissertation template. It should be pretty easy to also just write a converter that export to asciidoc or doocbook.
For those interested of the idea behing how nbconvert I wrote this quite some time ago: http://nbviewer.ipython.org/urls/raw.github.com/Carreau/post... and https://github.com/ipython/ipython-in-depth Offer some example too.
Hope this will push some people to contribute, we'll always be happy do guide you in your first step.
It is clunky but I'm hoping we'll get better control as nbconvert evolves, so we're experimenting with this approach.
Most of the code examples are not 'live', they're pasted in along with analysis results (the book is about high performance and parallel computing: http://shop.oreilly.com/product/0636920028963.do ), as lots of the examples are best run from a fresh VM.
https://github.com/ptwobrussell/Mining-the-Social-Web-2nd-Ed...
IMHO, this is what makes a duo like Vagrant + IPython Notebook so appropriate for creating a minimum barrier to entry. In other words, what you really need is a VM that has IPython Notebook and all of the necessary dependencies installed that you just start up as a guest machine. Then, on your host, you point your browser to http://localhost:8888 and get to work with the the ipynb UI.
The approach I described is exactly what I did with Mining the Social Web 2E, and I elaborated on it a bit here: http://miningthesocialweb.com/2013/08/24/reflections-on-auth...
The cool thing about the way Vagrant works is that you can run a VM locally or you can run it in the cloud just as easily with the appropriate plugin.
There's a video that demonstrates how easy it can be to use Vagrant and IPython Notebook to get started here - https://vimeo.com/72383764
All of this does not obviate the challenges of setting up IPython, but that could also be (somewhat)resolved via cloud services[4][5][6].
[1] http://gibiansky.github.io/IHaskell/
[2] https://github.com/mattpap/IScala
[3] https://github.com/JuliaLang/IJulia.jl
[4] http://www.windowsazure.com/en-us/develop/python/tutorials/i...
[6] http://blog.picloud.com/2012/12/23/introducing-the-picloud-n...
I would also love to see a publishing workflow that could render IPython Notebooks for print on dead trees.
One thing I'm hoping to figure out is a way to transform IPython Notebooks into PDFs that satisfy my university's dissertation formatting guidelines (one inch margins, 12pt times, etc).
[1] https://github.com/ipython/ipython/tree/master/IPython/nbcon...
O'Reilly does use docbook internally as part of the toolchain, but asciidoc is coming into style as well. I've done most of my work in docbook with a docbook editor, but did some of my latest boook in asciidoc, which was much easier. Just use a standard text editor of choice (like Vim) and get right to it. Much easier for me, anyway.
One thing I'd really like to see is ipynb supporting asciidoc instead of or in addition to markdown. You can go to/from asciidoc and docbook in a lossless way, IIRC.
[1] http://asciidoctor.org/news/2013/05/21/asciidoctor-js-render...
[2]https://github.com/scholmd/scholmd/wiki
[3]http://blog.martinfenner.org/2013/06/19/citations-in-scholar...
[4]http://www.codinghorror.com/blog/2012/10/the-future-of-markd...
What an awesome idea -- I can think of some sociologists/biologists who had to suffer through MS Word equation editor with excel charts who would love something like this. The internal hyperlinks would be awesome too.
For now, at least you can "decode" ipynb to LaTeX and use the %%latex magic.
http://nbviewer.ipython.org/urls/raw.github.com/fonnesbeck/B...
http://nbviewer.ipython.org/url/norvig.com/ipython/TSPv3.ipy...
I guess I'm asking, what's the difference between an HTML page that shows a Python implementation of an algorithm vs those links? Or what's the appeal?
I'm certain IPython Notebooks are valuable, since everybody seems to love them. It's not clear from glancing at those examples what the big deal is, though, so I thought I should ask in case more newbies come along and incorrectly conclude that there's nothing especially interesting about those examples beyond their content. (To be clear, the content is excellent, but why is IPython Notebook to thank rather than the author? Could those examples not have been done via some other method, or is the purpose of IPython Notebook just to make it really easy to generate such pages?)
Setting up that IPython notebook server is easy: check out this 2 min video (http://vimeo.com/72383764). Bonus: if you use the one provided in github in that link, it comes with all the python imports you'd already need like networkx, response, etc. :)
There are some videos that show this in action. One that I put together is here if you'd like to see a quick demo of it as it (rather generically) relates to Mining the Social Web - https://vimeo.com/72871930
The benefit of the IPython Notebook is sharable JSON file and interactive REPL-like environment that blends code, results, and narrative prose.
[1] http://ipython.org/ipython-doc/stable/interactive/notebook.h...
edit: I should have refreshed the page before I wrote this redundant reply.
One of the fun examples shows how to mine an RSS feed ;)
https://rawgithub.com/ptwobrussell/Mining-the-Social-Web-2nd...