Trading off of External Symbols
Author: rdevolde
Creation Date: 3/12/2009 3:48 PM
profile picture

rdevolde

#1
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?
profile picture

Eugene

#2
Yes, it's possible. See -

QuickRef:
SetContext

WealthScript Language Guide
Programming Trading Strategies > Multi-Symbol Strategies
DataSeries > Accessing Secondary Symbols
etc.

WL5 Wiki
Pairs Trading
profile picture

rdevolde

#3
Thanks Eugene, got it figured out!
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).