Floating point numbers

David Relson relson at osagesoftware.com
Mon May 5 13:39:07 CEST 2003


At 12:03 PM 4/30/03, Chris Ditri wrote:

>Hi...
>
>I Just installed .12.2 and I am getting scientific notion in my X-bogosity
>headers.
>
>You guys know about this?
>
>I am afraid of how this will affect the filtering process.   Anything we can
>do to fix this?
>
>
>Thanks,
>
>Chris

Chris,

Bogofilter's output formatting has the ability to display spamicity using 
fixed point, e.g. 0.123456, or as floating point, e.g. 1.23e-02.  I find 
the floating point to be useful with Robinson-Fisher since values are often 
_very_ close to 0.000000 or to 1.000000.

By "very close", I mean that they can be within 1e-6, 1e-10, or even 
closer.  Such close values would display as 0.000000 or 1.000000 (depending 
on whether it's ham or spam).  Bogofilter's "%d" formatting option takes 
values below 0.001 or above 0.999, computes the difference from 0.000000 
(for ham) or from 1.000000 (for spam) and prints the result using floating 
point.

Bogofilter's formatting uses "%p" for fixed point probabilities and uses 
"%d" for a floating point (delta) display.

The default setup is to used fixed point ("%p"), rather than floating point 
("%d").  Unless something is radically wrong, bogofilter.cf.example has 
"%p" in the "header_format=" line.

What do you have in your config file for that option?  Look whether you 
have "%p" or "%d".  Probably you have "%d" and you want "%p".

David






More information about the Bogofilter mailing list