Skip to content
All library documents

Real-Time Cross-Contract Signal Calculation with Custom Formulas

Article Quant course library

Summary

This module describes a real-time radar for calculating derived values from multiple contracts. Users define named rules with a Python mathematical expression and assign contract symbols to formula variables. Incoming tick data for any assigned contract triggers recalculation, allowing expressions for relationships such as inter-contract spreads or ratios.

Rules can be added, edited, removed, or imported in bulk from a CSV file, and the displayed result can be rounded to a chosen number of decimal places. The method depends on live market data subscriptions and requires the surrounding trading application to be connected before launching the radar. The described version only displays numeric results; it does not provide charting, alerts, strategy signal subscriptions, validation guidance, or evidence that any formula produces a profitable signal.

Key ideas

  • A rule combines live prices from assigned contracts using a custom mathematical expression.
  • Tick updates from any contract referenced by a rule trigger recalculation.
  • Rules can be managed individually or imported in bulk from a CSV file.
  • The output is a rounded numeric value, with no charting or alert behavior described.
  • Live connectivity and subscribed contract data are prerequisites for calculations.

Tags

From a private course collection; the original is not published.