The Math Editor Templates functionality extends the Math Editor by allowing users to define reusable calculation logic that can be invoked as custom functions. This capability is essential for standardizing complex calculations across the platform, ensuring consistency in pricing formulas, risk metrics, and operational analytics while reducing errors and maintenance overhead.
Typical Use Cases:
Standardized price indexation formulas: Define a template for calculating indexed contract prices based on market benchmarks (e.g., "IndexedPrice(BasePrice, IndexValue, EscalationFactor, CapRate)"). When multiple bilateral contracts use the same indexation methodology but with different parameters, the template ensures all contracts apply identical calculation logic, while business analysts can update the formula centrally if the methodology changes.
Composite operational KPIs: Build templates for complex performance indicators such as heat rate efficiency curves, capacity factor calculations adjusted for forced outages, or renewable asset availability metrics. When the same KPI definition needs to be applied across multiple assets or reporting periods, the template ensures methodological consistency and simplifies auditing.
Instead of repeating the same formula structure across multiple expressions, users can define a template once and reuse it wherever required. Each template contains the calculation expression, the defined input parameters, and the corresponding output configuration.
After synchronization, the template becomes available inside the Math Editor and can be called as a function with the specified input arguments, enabling modular, maintainable calculation architectures across the ETRM platform.
Accessing Math Editor Templates
The user can access this functionality through:
Data Room → Math Editor Templates
The main grid displays the available templates along with their key configuration attributes. From this screen, users can create new templates or edit and delete existing ones.
Creating a New Template
To create a new template:
Click the “+” button.
In the pop-up window, enter:
Name (mandatory)
Description (optional)
Confirm the initial creation.
Define the template configuration and click “Save” to store it.
Expression Configuration
The central editor area allows the user to define the calculation logic.
The syntax and behaviour follow the same principles as the Math Editor. The expression may reference the defined input parameters and apply operators and available system functions.
Input Parameters
In the configuration panel, the user defines the template input parameters.
For each input, the following must be specified:
Name (mandatory)
Type (selected from the available list)
Available input types include:
Decimal
Int
Boolean
Timeseries
DateTime
String
Entity (Deal, Asset or Counterparty)
List
Additional properties can be configured under Advanced Settings:
Description (optional)
UOM (Unit of Measure)
Required flag (defines whether the input is mandatory when the template is used)
Multiple inputs can be added through the “+ Add Input” option.
Output Configuration
The user must define the template output characteristics:
Output Type
UOM (Unit of Measure)
Testing the Template
Before saving or finalizing a template, the user may validate the logic through the Test Expression section.
The testing area allows the user to:
Define a Date Range
Select a Timezone
Specify Decimal Points
Optionally exclude timestamps with missing values
Provide test values for the defined input parameters
Execute the test using “Run Test”
Results are displayed in the available views (e.g. terminal, chart or data), allowing verification of the calculation.
Synchronizing Templates
After saving, the user may select “Sync Functions”.
Once synchronized:
The template becomes available within the Math Editor.
It can be invoked as a function using its defined name.
The defined input parameters are passed as arguments when calling the function.
Any subsequent modification of the template will apply to future executions where the template is used.