Altair® Panopticon

 

Supported Operators and Calculation Functions

This section lists the supported operators and calculation functions in Panopticon Streams.

  NOTE

Panopticon Streams supports nullability where:

·         a field may or may not allow null/empty/missing/NA values

·         functions or operators may or may not allow null arguments (e.g., you can’t divide seven by null)

 

 

 

Supported Operators

These are typically the operators that are used to create aggregation operator and calculation operator expressions.

Operator

Name

Description

Example

Nullability

!

Logical NOT

! boolean

Reverse arguments or results.

Parameter:

·         boolean – A value of logical expression that can be evaluated as TRUE or FALSE.

 

 

!=

Not Equal To

Tests if one value is not equals to another.

12.3 != 47.11 = true

a

%

Modulo

number % divisor

Gets the remainder from division.

Parameters:

·         number – The Number to be divided.

·         divisor – The number to divide with.

17 % 5 = 2

 

&&

Logical AND

Returns true only if both the conditions return true.

(7 > 5)&&(3 < 8) = true

 

*

Multiplication

Multiply

9 * 5 = 45

 

+

Addition

Adds two numbers or joins two or more text strings to produce a single piece of text.

47.11 + 9.7 = 56.81

 

-

Subtraction

Subsctracts two numbers.

47 – 11 = 36

 

/

Division

number / divisor

Parameters:

·         number – The number to be divided.

·         divisor – The number to divide with.

11 / 5 = 2

 

< 

Less than

Tests if one value is less (smaller) than another.

4 < 7 = true

 

<=

Less Than or Equal To

Tests if one value is less than or equal to another.

7 <= 4 = false

 

==

Equal To

Tests if one value is equals to another.

9 == 5 = false

a

> 

Greater Than

Tests if one value is greater (larger) than another.

7 > 4 = true

 

>=

Greater Than or Equal To

Tests if one value is greater or equal to another.

7 >= 4 = true

 

?:

Ternary IF

Provides branching capability. If condition is true, then it returns exprIfTrue, else returns exprIfFalse.

condition ? exprIfTrue : exprIfFalse

Parameters:

·         condition – A value or logical expression that can be evaluated as true or false.

·         exprIfTrue – The value to return when condition evaluates to true.

·         exprIfFalse - The value to return when condition evaluates to false.

 

a

^

Exponentiation

Get the exponential value of the number.

(2.0) ^ 7.0 = 128.0

 

like

Like

Tests if the pattern exists in the text.

‘olle’ like pattern(‘.ll.’) = true

 

||

Logical OR

Returns true if any of the conditions return true.

(7 > 5) || (3 > 8) = true

 

-

Negation

Negation of the number.

-(1 + 2 ) = -3

 

+

Positivity

Positivity of the number.

 

 

()

Cast Operator

Explicit data type conversion.

Valid casts are:

·         ‘int’

·         ‘real’

·         ‘text’

·         ‘time’

·         ‘bool’

(int)sqr(Numeric1)