RoundingDirectionEnum
Enum CDM 7.2.0The enumerated values to specify the rounding direction and precision to be used in the rounding of a number. Used by function cdm.base.math.RoundToPrecision.
Values 3
Namespace cdm.base.math
Values
3 permitted values.
| Value | Description |
|---|---|
| Up | A fractional number will be rounded up to the specified number of decimal places (the precision). For example, 5.21 and 5.25 rounded up to 1 decimal place are 5.3 and 5.3 respectively. |
| Down | A fractional number will be rounded down to the specified number of decimal places (the precision). For example, 5.29 and 5.25 rounded down to 1 decimal place are 5.2 and 5.2 respectively. |
| Nearest | A fractional number will be rounded either up or down to the specified number of decimal places (the precision) depending on its value. For example, 5.24 would be rounded down to 5.2 and 5.25 would be rounded up to 5.3 if a precision of 1 decimal place were specified. |
Referenced by
2 types hold a RoundingDirectionEnum as an attribute.
Functions
Model functions that produce or consume this type. These are the CDM's own behaviour — the logic a correct implementation has to match.
| Function | Role | Description |
|---|---|---|
| MapRoundingDirectionEnum | returns | — |
| RoundToPrecision | takes | Round a number to the supplied precision, using the supplied rounding direction. |
| RoundToSignificantFigures | takes | Round a number to the supplied significant figures, using the supplied rounding direction. |
Open RoundingDirectionEnum in the Model Browser
Walk the tree and the reference graph interactively, and switch releases to see how the enumeration has changed. Free, no signup.