Use indicators
Use your own indicator values in MesoSim by importing them through External CSV Data. The imported columns become variables that you can reference in strategy expressions to filter entries, trigger adjustments, or define exits.
Bring indicator data into your strategy
- Calculate the indicator outside MesoSim and export its values to a CSV file with a
dateordatetimecolumn and numeric indicator columns. - Share the CSV through GitHub Gist or Google Sheets, following the file and column requirements.
- Open your strategy in the AI Editor, add the CSV URL to
ExternalData.CsvUrl, and select Validate to load the variables. - Reference the imported variable names in your conditions. Check variable availability for the expression you are editing.
The built-in [FEAT-ExternalData-Csv] template provides an example. See the Strategy Library for more examples, including the Rhino strategy on the Deltaray blog.
Timestamp indicator values according to when they were available to the strategy. Date-only values are treated as end-of-day samples and become available the following day. See External CSV Data timing before running the backtest.
Apply indicators to trading rules
Use the imported values in entry conditions, conditional adjustments, or exit conditions. The Script Engine explains how to build expressions from variables.
After the first run, Clone the backtest and change one condition at a time to compare its effect in the results.
The built-in Indicators field was removed in v3. Replace it with externally calculated indicator data; see the Migration Guide.