- changed status to closed
display of plotting output in tutorial notebooks is inconsistent
in the tutorial notebooks, we sometimes want to demonstrate the use of the outfile
kwarg to write plot output to a file (showing it later using IPython.display.Image
), while at other times we want to show the plot inline with %matplotlib inline
we currently use %matplotlib notebook
to try to hide the plots that we are writing to file from being displayed inline in the notebook
this works on colab, but in a normal jupyter environment it shows the large interactive plotting UI (one per rep if parallelized) with no content (since the content is in a different figure that has been saved to disk by now)
we consider three possible solutions to hiding the plot output for these cells:
%matplotlib agg
: this does exactly what we want but it was only added in IPython 6.0 which only supports Python 3, see this issueplt.close()
: this hides the UI but leaves behind a giant rectangle that is tricky to collapse programmatically, see this issue%%capture
: this feels like an indirect way of solving the problem but it works on colab and in jupyter, see this SO answer
Comments (2)
-
reporter -
reporter we ended up going with the
%%capture
strategy in the commit referenced above - Log in to comment
wip on notebook building
closes
#57added gmean_20_8 binning to default pipeline config so we can use it in the tutorial
temporarily changed tutorials/run.py to run only the scripting tutorial for testing purposes
first stab at tutorial build pipeline in bibucket
→ <<cset 93e277d38bf8>>