.. _floor: ===== floor ===== Rounds down to the next lowest integer Description ~~~~~~~~~~~ The fn:floor function returns the largest integer that is not greater than $arg. The result type depends the numeric type of the argument. If $arg is untyped, it is cast to xs:double. .. list-table:: :widths: 40 60 :header-rows: 1 * - **Parameters** - **Description** * - arg:numeric() - Examples ~~~~~~~~ .. list-table:: :widths: 50 50 :header-rows: 1 * - **XPath** - **Results** * - floor(5) - 5 * - floor(5.1) - 5 * - floor(5.7) - 5 * - floor(-5.1) - -6 * - floor(-5.7) - -6 * - floor( () ) - () See Also ~~~~~~~~ .. toctree:: :titlesonly: :glob: * :ref:`ceiling`. * :ref:`round`. * :ref:`round-half-to-even`.