ABS Function (OpenOffice Calc)
The ABS function in OpenOffice Calc returns the absolute value of a number. Learn syntax, examples, behavior with negative numbers, common errors, and best practices.
Compatibility
▾| Excel | ✔ |
| Gnumeric | ✔ |
| Google_sheets | ✔ |
| Libreoffice | ✔ |
| Numbers | ✔ |
| Onlyoffice | ✔ |
| Openoffice | ✔ |
| Wps | ✔ |
| Zoho | ✔ |
What the ABS Function Does â–¾
- Converts negative numbers to positive
- Leaves positive numbers unchanged
- Works with decimals, integers, and dates
- Useful for error correction, distance calculations, and normalization
- Works across sheets
ABS is ideal when you need the magnitude of a value without regard to sign.
Syntax â–¾
ABS(number)
Arguments:
- number — Any numeric value, reference, or formula result
ABS does not modify text, empty cells, or logical values.
Basic Examples â–¾
Convert a negative number to positive
=ABS(-7)
Result: 7
Absolute value of a positive number
=ABS(12.5)
Result: 12.5
Absolute value of a formula result
=ABS(A1 - B1)
Absolute value of a range (array formula)
=ABS(A1:A10)
Confirm with Ctrl+Shift+Enter.
Advanced Examples â–¾
ABS for financial variance
=ABS(Actual - Budget)
Useful for dashboards where only magnitude matters.
ABS for distance between two values
=ABS(A1 - A2)
ABS for error measurement
=ABS(Measured - Expected)
ABS with conditional logic
Highlight large deviations:
=ABS(A1 - B1) > 10
ABS across sheets
=ABS(Sheet1.A1)
ABS with negative dates or times
=ABS(A1 - B1)
Returns the magnitude of the time difference.
ABS in array math
=SUM(ABS(A1:A10 - B1:B10))
Confirm with Ctrl+Shift+Enter.
Common Errors and Fixes â–¾
ABS returns 0 unexpectedly
Possible causes:
- Input is text, not a number
- Input cell is empty
- Formula result is exactly 0
ABS returns Err:502 (Invalid argument)
Occurs when:
- Argument is non-numeric text
- A malformed reference is used
ABS returns Err:508 (Missing parenthesis)
Usually caused by:
- Missing
) - Using commas instead of semicolons
ABS ignores values you expected it to include
ABS ignores:
- Text numbers (
"123") - Empty cells
- Logical values (TRUE/FALSE)
- Errors
ABS includes values you expected it to ignore
ABS includes:
- Dates
- Times
- Numeric results of formulas
Best Practices â–¾
- Use ABS for magnitude-based comparisons
- Use ABS in dashboards to show deviation size
- Use ABS with conditional formatting for alerts
- Convert imported text numbers to real numbers
- Use named ranges for cleaner formulas
ABS is extremely powerful when combined with SUM, AVERAGE, and conditional formatting to highlight large deviations.