Can I use a conditional to use two separate strategies?


Category:
0
0

Howdy,

I am just learning how to code in thinkscript (no previous experience in coding). But after tinkering with other people’s sample scripts coupled with few of my own, I was able to come up with some useful, albeit basic, strategies. So far, I have two separate strategies, one for the trend and another for the rangebound. The codes used for the two are kinda opposite (although not identical) to one another, and I can’t just combine the two codes into one strategy. Hence my question. Is there a way to use a conditional to tell TOS to use the trending strategy when X occurs and use the rangebound strategy when Y occurs?

Thanks.

Marked as spam
Posted by (Questions: 1, Answers: 0)
Asked on November 15, 2019 9:43 pm
91 views
0
Private answer

The Conditional Order tool in Thinkorswim must contain the entire code you want to use. So if you want the Conditional Order to use one or the other than both will need to be incorporated into a signal piece of code. Then include additional code that tells which signal to use under your specific conditions.

Marked as spam
Posted by (Questions: 37, Answers: 4087)
Answered on November 16, 2019 8:30 am