[Matplotlib-users] AssertionError error when writing to SVG with pyplot.savefig()

2012-03-18 Thread Ben Harrison
Hello, below I've included my script for plotting some data, and a small amount of the data itself. I plot the data to several different file types via pyplot.savefig(). For each of eps, pdf, and png, it works fine. With svg it throws this error, any ideas why?: harb@joan:~/Documents/DATA/Appl

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread klo uo
After parsing matplotlibrc, I browsed module where errorbars are defined (axes.py) and tried changing various variables without success. In bar() function (line 4628) there is "adjust_xlim = False" line which calls line 4768 if set True. So I set it True, to find it's buggy if x starts from 0 (mos

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread Tony Yu
On Sun, Mar 18, 2012 at 11:08 AM, Benjamin Root wrote: > > > On Sunday, March 18, 2012, Tony Yu wrote: > > > > > > On Sun, Mar 18, 2012 at 9:14 AM, klo uo wrote: > >> > >> On Sun, Mar 18, 2012 at 1:50 PM, Angus McMorland > wrote: > >>> > >>> For inline ipython, you want to switch to the object

[Matplotlib-users] 3d plotting

2012-03-18 Thread David Craig
Hi, I'm using surface_plot to view the results of solving the 2d wave equation. It works fine (code is below) except I would like to add a color bar and fix the limits on the vertical axis. When I add the color bar a new one is added in every iteration instead of overwriting the previous one, anyon

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread Benjamin Root
On Sunday, March 18, 2012, Tony Yu wrote: > > > On Sun, Mar 18, 2012 at 9:14 AM, klo uo wrote: >> >> On Sun, Mar 18, 2012 at 1:50 PM, Angus McMorland wrote: >>> >>> For inline ipython, you want to switch to the object-oriented use of >>> pylab. Something like this should work with xlim. >>> >>>

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread Tony Yu
On Sun, Mar 18, 2012 at 9:14 AM, klo uo wrote: > On Sun, Mar 18, 2012 at 1:50 PM, Angus McMorland wrote: > >> >> For inline ipython, you want to switch to the object-oriented use of >> pylab. Something like this should work with xlim. >> >> a = [0.1, 0.2, 0.1] >> fig = plt.figure() >> ax = fig.ad

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread klo uo
On Sun, Mar 18, 2012 at 1:50 PM, Angus McMorland wrote: > > For inline ipython, you want to switch to the object-oriented use of > pylab. Something like this should work with xlim. > > a = [0.1, 0.2, 0.1] > fig = plt.figure() > ax = fig.add_subplot(111) > ax.errorbar(arange(3), a, yerr=a-sum(a)/l

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread Angus McMorland
On 18 March 2012 08:43, klo uo wrote: > On Sun, Mar 18, 2012 at 1:07 PM, Angus McMorland wrote: >> >> >> >> The xlim command can be used to set the x limits. For example: >> >> xlim(-.5, 2.5) >> >> will prevent the points lying on the axis boundaries for your case. >> > > Thanks Angus, > > that w

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread klo uo
On Sun, Mar 18, 2012 at 1:07 PM, Angus McMorland wrote: > > > The xlim command can be used to set the x limits. For example: > > xlim(-.5, 2.5) > > will prevent the points lying on the axis boundaries for your case. > > Thanks Angus, that worked with ease for separate MPL window, but not inline

Re: [Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread Angus McMorland
On 18 March 2012 04:39, klo uo wrote: > Assuming IPython in pylab mode: > > a = [0.1, 0.2, 0.1] > errorbar(arange(3), a, yerr=a-sum(a)/len(a), fmt='ro') > > Result MPL output clips limit values in two different ways: > > 1. If GTK backend is used both left and right sides are clipped > 2.

[Matplotlib-users] Why are bars, errorbars... clipped

2012-03-18 Thread klo uo
Assuming IPython in pylab mode: a = [0.1, 0.2, 0.1] errorbar(arange(3), a, yerr=a-sum(a)/len(a), fmt='ro') Result MPL output clips limit values in two different ways: 1. If GTK backend is used both left and right sides are clipped 2. If IPyhton inline mode is used, only right side is cli