Is it possible to create a new Bars object, filling it's OHLC with custom values, and trade with this new Bars (setting it as the context)?
If so, how?
Thanks
Size:
Color:
Create, fill its OHLC, save as a disk file, load from disk - yes,
Trade - no, not on-the-fly. The synthetic symbol should exist in one of your DataSets in order to work with SetContext.
Size:
Color:
Thought I post an update here. V6.9 brought the ability to create and backtest synthetic option symbols. As a side effect, trading on the virtual Bars object such as a synthetic option contract is possible by virtue of a new SetContext overload. Such trades will not appear on the primary instrument's chart. Workaround's in the FAQ:
Is there a way to see the trades on secondary symbols?
Size:
Color:
QUOTE:
Trade - no, not on-the-fly. The synthetic symbol should exist in one of your DataSets in order to work with SetContext.
QUOTE:
V6.9 brought the ability to create and backtest synthetic option symbols
And the ability to create and trade on-the-fly any synchronized synthetic symbol without saving it to disk also came with V6.9. A synthetic symbol may be traded with
CODE:
Please log in to see this code.
Size:
Color: