Components of the rule expression language

Component Description

Operators and literals

Operators and literals connect information in the rule expression.

Use standard C# and Java operators and literals to create rule expressions.

Data

Data includes the following:

  • Values provided for study objects within the scope of the rule.
  • Values of rule model properties of study objects within the scope of the rule.
  • Methods for repeating study objects.

Functions

A function is a reusable piece of code that extends the behavior of a rule. Functions allow experienced programmers to build complex rule expressions and make them available in libraries or studies. A function can be part or all of a rule expression.

If a function has parameters, you must specify their substitution values after you drag the function into the rule expression. You can use the following to specify parameter substitution values:

  • Numeric values.
  • Values of study objects and their rule model properties.
  • Constants.
  • Another function.
  • Global study objects and their rule model properties.

Constants

A constant is a value that is defined in a library or study and that can be referenced by any rule.

Data mappings

Study objects and properties that have a global scope for rule creation are called data mappings. The following data mappings can be used in any rule in the study in which you are working:

  • RefNames of the following study objects in the study or library:
    • Mappings.
    • Data sets.
    • Data series.
    • Items added to data series.
  • Methods for data sets.

    Methods are automatically available for all data sets.

  • Rule model properties for data series.

    If the data series contains one or more items that collect more than one value, then the rule model properties for data series appear so you can specify the value to use.

Methods

A method is a block of code that is called by a rule and that is used to manipulate data. You can use any method, including:

  • Math methods.
  • Methods for repeating study objects.
  • Data set methods.