Numeric Functions
AMPS includes the following functions for working with numbers.
Function | Parameters | Description |
---|---|---|
| number | Returns the absolute value of a number. For example, the following filter will be TRUE when the difference between |
| list of numbers to compare | Returns the largest of the provided numbers, or |
| list of numbers to compare | Returns the smallest of the provided numbers, or |
| number to round | Returns the value rounded upward to the next greatest integer. Returns an integer unchanged. |
| number to round | Returns the value rounded downward to the next lower integer. Returns an integer unchanged. |
| exponent to use | Returns e raised to the power of the provided exponent. |
| number | Returns the natural logarithm of the provided number. |
| number | Returns the base-2 logarithm of the provided number. |
| number | Returns the base-10 logarithm of the provided number. |
| base, exponent | Returns the value of base raised to the power of exponent. |
| number | Returns the square root of the provided number. |
| number | Returns the cosine of the provided number. |
| number | Returns the arcosine of the provided number. |
| number | Returns the sine of the provided number. |
| number | Returns the hyperbolic sine of the provided number. |
| number | Returns the arcsine of the provided number. |
| number | Returns the hyperbolic cosine of the provided number. |
| number | Returns the cotangent of the provided number. |
| number | Returns the arctangent of the provided number. |
| number, number | Returns the arctangent of the provided numbers. |
| number | Returns the tangent of the provided number. |
| number | Returns the hyperbolic tangent of the provided number. |
| string | Returns the MD5 checksum of the provided string. |
| number | Returns the provided number converted from degrees to radians. |
| number | Returns the provided number converted from radians to degrees. |
| number | Returns the sign of the provided number. If the number is less than |
| number, [number of decimal places] | Returns a number rounded to the specified number of decimal places. The number of decimal places is optional. When not provided, the number defaults to 0. The number of decimal places can be positive or negative. When the number is positive, the number specifies the number of digits to the right of the decimal place to round at. When the number is negative, the number specifies the number of digits to the left of the decimal place to round at. For example, you could use the following expression in a view to limit the precision of the |
| expression, min, max, bucket count | The bucket count argument specifies the number of buckets to create over the range defined by min and max. min is inclusive, while max is not. The value from expression is assigned to a bucket, and the function returns a corresponding bucket number.
When expression falls outside the range of buckets, the function returns either |
Last updated