from IPython.display import HTML import plotly.plotly as py from pylab import * import plotly.tools as tls plot(rand(100)) p=py.plot_mpl(gcf(), auto_open=False, filename='test') ## standard embedding e = tls.embed(p) ##editable embedding, allows seamless interactive plotly-ness def get_embed_n_edit(p, *args, **kwargs): s = p.split('/') s_edit = '/'.join([k for k in s[:-2]+[s[-1],s[-2]]]) e = tls.get_embed(p, *args, **kwargs) return e.replace(p,s_edit) def embed_n_edit(p, *args, **kwargs): return HTML(get_embed_n_edit(p, *args, **kwargs)) embed_n_edit(p, height =800) # see the updated plot (once saved) tls.embed(p)