Rounding off problem.

Stephen J. Gowdy gowdy at slac.stanford.edu
Mon Mar 24 18:41:17 EDT 2008


Round to an even number in the case of .5, I think someone mentioned that 
already.

On Mon, 24 Mar 2008, Geoffrey wrote:

> David Brown wrote:
>> On Mon, Mar 24, 2008 at 04:05:32PM -0400, Geoffrey wrote:
>>
>>> I would expect neither.  I would expect that if rounded, it should
>>> round to 20,001.00.
>>>
>>> Your first suggestion would be rounding down.  I've never seen
>>> anything like your second suggestion, unless it's a typo and meant,
>>> 20,001.00.
>>
>> Sorry, that was a typo.  I meant either rouding to the nearest even
>> integer, or rounding up when in the middle.  The problem with always
>> rouding the $0.50 up is that it introduces a slight bias to the result.
>
> In that case, there are very specific rules to rounding.  5 or greater,
> round up, less then 5 round down.
>
> The bias issue is understood, but it's also a fact of life, I can't help
> you there. :)
>
>>
>> David
>>
>
>
> --
> Until later, Geoffrey
>
> Those who would give up essential Liberty, to purchase a little
> temporary Safety, deserve neither Liberty nor Safety.
>  - Benjamin Franklin
> _______________________________________________
> gnucash-user mailing list
> gnucash-user at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> -----
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
>

-- 
  /------------------------------------+-------------------------\
|Stephen J. Gowdy                     | CERN       Office: 8-1-11|
|http://www.slac.stanford.edu/~gowdy/ | CH-1211 Geneva 23        |
|                                     | Switzerland              |
|EMail: gowdy at cern.ch                 | Tel: +41 22 767 5840     |
  \------------------------------------+-------------------------/


More information about the gnucash-user mailing list