{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Notebook snippets, tips and tricks" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "**TODO**:\n", "* Read https://www.dataquest.io/blog/jupyter-notebook-tips-tricks-shortcuts/\n", "* Read http://blog.juliusschulz.de/blog/ultimate-ipython-notebook\n", "* howto avoid loosing matplotlib interactive rendering when a document is converted to HTML ?\n", " * https://www.reddit.com/r/IPython/comments/36p360/try_matplotlib_notebook_for_interactive_plots/\n", " * http://stackoverflow.com/questions/36151181/exporting-interactive-jupyter-notebook-to-html\n", " * https://jakevdp.github.io/blog/2013/12/05/static-interactive-widgets/\n", "* table of contents (JS)\n", "* matplotlib / D3.js interaction\n", "* matplotlib animations: how to make it faster\n", "* inspiration\n", " * http://louistiao.me/posts/notebooks/embedding-matplotlib-animations-in-jupyter-notebooks/\n", " * https://github.com/ltiao/notebooks\n", " * https://blog.dominodatalab.com/lesser-known-ways-of-using-notebooks/\n", "* Howto make (personalized) Reveal.js slides from this notebook: https://forum.poppy-project.org/t/utiliser-jupyter-pour-des-presentations-etape-par-etape-use-jupyter-to-present-step-by-step/2271/2\n", "* See https://blog.dominodatalab.com/lesser-known-ways-of-using-notebooks/\n", "\n", "Extension wishlist and todo:\n", "- Table of content\n", "- Hide some blocks in the HTML export\n", " - See https://github.com/jupyter/notebook/issues/534\n", "- Customize CSS in HTML export\n", "- Add disqus in HTML export\n", " - See: https://github.com/jupyter/nbviewer/issues/80\n", " - Example: http://nbviewer.jupyter.org/gist/tonyfast/977184c1243287e7e55e\n", "- Add metadata header/footer (initial publication date, last revision date, author, email, website, license, ...)\n", "- Vim like editor/navigation shortcut keys (search, search+edit, ...)\n", "- Spell checking\n", " - See https://github.com/ipython/ipython/issues/3216#issuecomment-59507673 and http://www.simulkade.com/posts/2015-04-07-spell-checking-in-jupyter-notebooks.html\n", " \n", "Inspiration:\n", "- https://github.com/jupyter/jupyter/wiki/A-gallery-of-interesting-Jupyter-Notebooks" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "%%html\n", "
" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "%%javascript\n", "var toc = document.getElementById(\"toc\");\n", "toc.innerHTML = \"Table of contents:\";\n", "toc.innerHTML += \"