Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VBA Number Rounding

Hi,

Jerry wrote:

Those problems aside, the availability of a Round
function that rounds
in this way is a welcome addition. You wouldn't
know it from MS
documentation (which calls it "Banker's" rounding
despite the fact that
banker's don't seem to use it), but this is type of
rounding is
specified by ASTM, IEEE, and most other standards
bodies that choose to
define rounding. It is usually a better way to handle
data, because it
tends to minimize the impact of accumulated
rounding errors on
subsequent calculations, because it tends to equalize
the number of
times that you round up vs. round down. As such it
is sometimes called
"unbiased" rounding.


I struggle with the explanation that this reduces bias (unless you are
looking at a non random distribution that is already biased to return
values exactly on the 0.5 points).

If you use 'true' rounding, then everything from N to N+4.9999
(recurring) inclusive will be rounded 'down' to N, and everyting from
N+0.5 to N+0.9999 (recurring) will be rounded 'up' to N+1 (where N is
an integer number - consider it positive for the sake of this
discussion).

This is a symmetrical rounding 'function' and as such is unbiased.

If we now redefine to use what was referred to above as Banker's
rounding, and round down approximately half the time when we have a
value of N+0.5, we have made the function non-symmetrical, and hence
biased.

The only excpetion would be if we have a sample that returns discrete
values, that may include N+0.5 more often that we would otherwise
expect, in which situation there may be a case.

Does this make sense?

Alan.



------------------------------------------------
~~ Message posted from http://www.ExcelTip.com/
~~ View and post usenet messages directly from http://www.ExcelForum.com/

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Rounding to every 5th whole number LHS Excel Discussion (Misc queries) 4 October 3rd 08 10:22 AM
Rounding number to 0.25 ? Construk Excel Discussion (Misc queries) 5 July 17th 07 10:38 PM
number rounding tamiluchi Excel Worksheet Functions 8 April 20th 06 06:05 PM
How do I keep a value from rounding up to the next number? Abby Excel Worksheet Functions 1 January 5th 05 09:07 PM
Rounding a number to a multiple quantity that adds to a fixed total number wjlo Excel Worksheet Functions 1 November 9th 04 04:43 PM


All times are GMT +1. The time now is 05:39 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"