1 May 23:13
Re: Improved histogram w/multiple types
No one thinks this is worth committing to SVN? I find myself using it quite a bit in my own work - different fields have different ideas about the "right" way to draw a histogram, so it's good to have options, I think... On Wed, Apr 2, 2008 at 4:39 PM, Erik Tollerud <erik.tollerud@...> wrote: > I've made some alterations to the hist() function in axes.py (attached > is a diff against the current SVN version). I've added the capability > to use the same interface to make outline histograms instead of bar > histograms (and a third option for outlines with fill - note that this > is NOT the same as calling it twice with the other two, as the widths > are slightly different). There's a slight compatibility issue in that > as it stands in that the returned tuple now has 4 values (I added a > list of the lines that are generated if the steps command is used), > but I can't really imagine how that could break anything but the > poorest-written code... Anyone think this is worth committing to SVN? > > (One thing that bothers me a little is the part of the code that adds > the last two edges to the histogram - the problem is that if you have > a line size greater than 1, the outline overshoots the rest of the > outline by a very tiny bit... if anyone knows how to cut off the upper > row of pixels to make it flush with the rest of the outline... it's > perfectly usable as-is, though - that's just a tiny little aesthetic > quibble) > > -- > Erik Tollerud > Graduate Student > Center For Cosmology(Continue reading)
RSS Feed