These are chat archives for sandialabs/toyplot

7th
Feb 2017
Hannes
@fnorf
Feb 07 2017 10:09
hey, i am using toyplot in jupyter notebooks, it rules!
can i interactively update an existing plot with new data or style changes? i love ipython's interact function and this would be a great combination
Timothy M. Shead
@tshead2
Feb 07 2017 19:15
Really happy to hear it!
Timothy M. Shead
@tshead2
Feb 07 2017 19:21
You can’t make changes to an existing plot, but you can recreate the plot from scratch in your interact() function and it will work fine (within limits). The trick is to use IPython.display.clear_output(wait=True) to clear the cell before generating the new plot. Note that you can do this from any loop, not just interact(). I use it to generate realtime displays with data logging software such as http://pipecat.readthedocs.io/en/latest/battery-chargers.html