I was wondering if there is a way to use external symbols such as the Dow Jones (.DJI) symbol as a criteria for entering into a different symbol. For example, I would like to only enter individual stocks if I am currently holding an active position in .DJI. Currently I am using the GetExternalSymbol function to import the .DJI data and am able to code for individual properties such as moving averages at the current bar I am trading on, but since I am not using a reversal system, I have different buy and sell criteria. Is there a way that I can "enter" into a .DJI position w/o actually using portfolio capital such that I would be able to see if I was currently holding an active position in .DJI?
Size:
Color:
Yes, it's possible. See -
QuickRef:
SetContextWealthScript Language GuideProgramming Trading Strategies > Multi-Symbol Strategies
DataSeries > Accessing Secondary Symbols
etc.
WL5 WikiPairs Trading
Size:
Color:
Thanks Eugene, got it figured out!
Size:
Color: