Re: [Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread John Salvatier
Ah, yes, I should have added that I have a lot of them, so this seems like improper usage. I found the collections.LineCollection class which sounds like what I want. Thank you for the help, John On Fri, Dec 10, 2010 at 12:34 PM, Chloe Lewis wrote: > You can plot them all individually; e.g. > >

Re: [Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread Chloe Lewis
You can plot them all individually; e.g. rec = ([1,2,.5], [0.5, 3, 1.1], [5, 7, .2]) for r in rec: pylab.plot( r[:2], [r[2]]*2) On Dec 10, 2010, at 12:13 PM, John Salvatier wrote: > I have a set of records with (start, end, value) values. Basically > they represent "we had this value betw

[Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread John Salvatier
I have a set of records with (start, end, value) values. Basically they represent "we had this value between these two times". The end of one record is not necessarily the end of another record. I would like to plot a set of line segments with end points (x=start, y= value) and (x=end, y=value),