The Excel Floor function is one of fifteen rounding functions in Excel.
A full list, along with comparison tables, is provided on the Excel Rounding Functions page.The Excel FLOOR function rounds a supplied number towards zero to the nearest multiple of a specified significance.
The syntax of the function is:
Where the arguments are as follows:
number | - | The number that is to be rounded. |
significance | - |
The multiple of significance that the supplied number is to be rounded to. (This should generally have the same arithmetic sign (positive or negitive) as the supplied number argument). |
Note: In Excel 2003 & 2007, the significance argument must have the same arithmetic sign (positive or negative) as the number argument. If they have different arithmetic signs, the Floor function returns an error.
However, in later versions of Excel, the Floor function has been improved, so that it can now handle a negative number argument and a positive significance argument. In this case, the Floor function reverses the direction of the rounding (i.e. rounds the supplied number away from zero).In column B of the following spreadsheet, the Excel Floor function is used to round the positive and negative numbers 26.75 and -26.75 to different multiples of significance.
Formulas:
|
Results:
|
The above examples show how, when the number and the significance arguments have the same arithmetic sign, the Floor function rounds the supplied number towards zero.
Different combinations of positive and negative arguments, are shown in the spreadsheet below.
The results shown are those that would be obtained in current versions of Excel (2010 or later).
Formulas:
|
Results:
|
This example shows how:
For further details of the Excel Floor Function, see the Microsoft Office website.
If you get an error from the Excel Floor function, this is likely to be one of the following:
#NUM! | - | Occurs: | ||||||
|
||||||||
#DIV/0! | - | Occurs if the supplied significance argument = 0. | ||||||
#VALUE! | - | Occurs if one or both of the supplied arguments is non-numeric. |