Difference between revisions of "Documentation/How Tos/Calc: ROUND function"

From Apache OpenOffice Wiki
Jump to: navigation, search
m (Robot: Automated text replacement %s)
m
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__NOTOC__
+
{{DISPLAYTITLE:ROUND function}}
 +
{{Documentation/CalcFunc MathematicalTOC
 +
|ShowPrevNext=block
 +
|PrevPage=Documentation/How_Tos/Calc:_TRUNC_function
 +
|NextPage=Documentation/How_Tos/Calc:_ROUNDDOWN_function
 +
}}__NOTOC__
  
 
== ROUND ==
 
== ROUND ==
Line 23: Line 28:
 
: returns <tt>'''1000'''</tt>
 
: returns <tt>'''1000'''</tt>
  
If these examples do not seem to work, see '''Tools - Options - OpenOffice.org Calc - Calculate''' to check the display precision.  
+
If these examples do not seem to work, see {{menu|Tools|Options|OpenOffice Calc|Calculate}} to check the display precision.  
  
{{Documentation/SeeAlso|
+
{{SeeAlso|EN|
 
* [[Documentation/How_Tos/Calc: INT function|INT]]
 
* [[Documentation/How_Tos/Calc: INT function|INT]]
 
* [[Documentation/How_Tos/Calc: TRUNC function|TRUNC]]
 
* [[Documentation/How_Tos/Calc: TRUNC function|TRUNC]]
Line 38: Line 43:
 
* [[Documentation/How_Tos/Calc: Functions listed alphabetically|Functions listed alphabetically]]
 
* [[Documentation/How_Tos/Calc: Functions listed alphabetically|Functions listed alphabetically]]
 
* [[Documentation/How_Tos/Calc: Functions listed by category|Functions listed by category]]}}
 
* [[Documentation/How_Tos/Calc: Functions listed by category|Functions listed by category]]}}
[[Category: Documentation/Reference/Calc]]
+
[[Category: Documentation/Reference/Calc/Mathematical functions]]

Latest revision as of 14:38, 31 January 2024

ROUND

Rounds a number to a certain precision.

Syntax:

ROUND(number; places)

returns number rounded to places decimal places. If places is omitted or zero, the function rounds to the nearest integer. If places is negative, the function rounds to the nearest 10, 100, 1000, etc.
This function rounds to the nearest number. See ROUNDDOWN and ROUNDUP for alternatives.

Example:

ROUND(2.348; 2)

returns 2.35

ROUND(2.348; 0)

returns 2

ROUND(2.5)

returns 3

ROUND(987.65; -2)

returns 1000

If these examples do not seem to work, see Tools → Options → OpenOffice Calc → Calculate to check the display precision.



See Also
Retrieved from "https://wiki.openoffice.org/w/index.php?title=Documentation/How_Tos/Calc:_ROUND_function&oldid=259859"
Views
Personal tools
Navigation
Tools
In other languages