"Fuzzy" Counter?

Rob Gaddi rgaddi at technologyhighland.invalid
Fri Sep 26 15:36:46 EDT 2014


On Fri, 26 Sep 2014 15:10:43 -0400
random832 at fastmail.us wrote:

> On Fri, Sep 26, 2014, at 14:30, Rob Gaddi wrote:
> > The "histogram" bin solution that everyone keeps trying to steer you
> > towards is almost certainly what you really want.  Epsilon is your
> > resolution.  You cannot resolve any information below your resolution
> > limit.  Yes, 1.49 and 1.51 wind up in different bins, whereas 1.51 and
> > 2.49 are in the same one, but that's what it means to have a resolution
> > of 1; you can't say anything about whether any given count in the "2,
> > plus or minus a bit" bin is very nearly 1 or very nearly 3.
> 
> You could "antialias" the values, though. 1.49 results in a value that
> is 51% in the "1" bin, and 49% in the "2" bin. count[1] += 0.51,
> count[2] += 0.49. You could even spread each value across a larger
> number of smaller bins.

Right, but there's still that stateless determination of which bin (or
bins) 1.49 goes in.  The history of the bins is irrelevant, which is
the important part.

-- 
Rob Gaddi, Highland Technology -- www.highlandtechnology.com
Email address domain is currently out of order.  See above to fix.



More information about the Python-list mailing list