Function round() calculates the nearest value of a given number, corrected to a designated position of digit; when two nearest values are found, returns the one with larger absolute value.
Arguments:
Returns:
Example: Direct calculate
UQLuncollect [-3.75, 7.55] as a uncollect [0, 1] as b return table(a, b, round(a, b))
Result| a | b | round(a, b) | |-------|---|-------------| | -3.75 | 0 | -4 | | 7.55 | 1 | 7.6 |
Example: Multiply and calculate
UQLuncollect [-3.75, 7.55] as a uncollect [0, 1] as b with round(a, b) as c return table(a, b, c)
Result| a | b | c | |-------|---|------| | -3.75 | 0 | -4 | | -3.75 | 1 | -3.8 | | 7.55 | 0 | 8 | | 7.55 | 1 | 7.6 |