Re: [Matplotlib-users] Is it planned to add copy/paste curves possibility in matplotlib ?

2014-12-12 Thread Julien Hillairet
r names >> aren't coming to me right now. >> >> Cheers! >> Ben Root >> >> >> On Thu, Dec 11, 2014 at 11:28 AM, Julien Hillairet < >> julien.hillai...@gmail.com> wrote: >>> >>> Dear all, >>> >>> We're, a

[Matplotlib-users] Is it planned to add copy/paste curves possibility in matplotlib ?

2014-12-11 Thread Julien Hillairet
Dear all, We're, at our lab, trying to (slowly) make the transition from a famous (but expansive) numerical software to Python. The most recurring remark made against the use of Python/Matplotlib instead of this famous software is the fact that one cannot male simple click/copy/paste of a curve f

Re: [Matplotlib-users] savefig and StringIO error on Python3

2014-11-02 Thread Julien Hillairet
embed images take a look at this Wikipedia page for some helpful information > http://en.wikipedia.org/wiki/Data_URI_scheme > > Apologies if you were expecting a more detailed answer, > Scott > > > On Nov 1, 2014, at 4:37 PM, Julien Hillairet > wrote: > > > Indeed, it works al

Re: [Matplotlib-users] savefig and StringIO error on Python3

2014-11-01 Thread Julien Hillairet
ue()).decode()) > > > For python 2.7.8 change html =""" to > > html = """ > > """ % base64.encodestring(sio.getvalue()) > > Best regards, > Scott > > > On Nov 1, 2014, at 7:37 AM, Julien Hillairet > wrote: > &g

Re: [Matplotlib-users] savefig and StringIO error on Python3

2014-11-01 Thread Julien Hillairet
t; import base64 > > fig = plt.figure() > ax = fig.add_subplot(111) > ax.plot([1,2,3]) > > sio = BytesIO() > > fig.savefig(sio, format="png") > > html = """ > > """.format(base64.encodebytes(sio.getvalue()).decode()) > > > Fo

[Matplotlib-users] savefig and StringIO error on Python3

2014-11-01 Thread Julien Hillairet
Dear all, I'm trying to write a html page content in which a png figure is generated by matplotlib, with Python3. However, the following piece of code does not work with matplotlib/Python3 (while it should work with Python2). The error is the following on TypeError: string argument expected, got