Allow only one strategy to execute a trade
Forums › ProRealTime English forum › ProOrder support › Allow only one strategy to execute a trade
- This topic has 13 replies, 6 voices, and was last updated 5 years ago by robertogozzi.
-
-
05/05/2017 at 10:06 AM #34609
Hello Team
I want to run few strategies simultaneously.
However, I want to allow only one strategy to execute a trade (Which comes first)..
So strategies X,Y,Z are running..
If X has been executed a trade, then Y and Z can not execute even though the strategy condition been met.Any ideas?
Thanks,
A.05/05/2017 at 5:32 PM #34653Put a suggestion to PRT using the Suggestion Box form below.
Seems like a good idea … reduces worry of High Drawdowns and Margin Calls.
Suggest also that PRT have a drop down box to select 1, 2, 3, more etc Bots running at same time.
Let me know if you do / don’t it else I’ll put it in? 😉
GraHal
PS More I think about, it’s a great idea … we could have loads of Bots running Live, but know that when we wake in the morning only 1 or 2 etc could be trading?
Okay we may miss big profits on one Algo by taking a earlier trade on another Algo, but I can live / sleep with that! 🙂
05/05/2017 at 6:35 PM #34656I forgot the link to the Form Doh! 😉
05/06/2017 at 5:37 AM #34664Ok, Thanks.
So I’m guessing there is no way to program this at this stage..??that’s a bit lame.
This is a basic risk management.
Anyway, I have sent them a message.
Thanks,
A.05/06/2017 at 8:27 AM #34667This is a basic risk management.
Hi algotrader, you are absolutely right, I have put this on here in the suggested improvements and filled out the form and sent it direct to IT-Finance, the more of us who do that the sooner we will get this essential functionality.
05/06/2017 at 9:59 AM #34674Great stuff!!
The more the merrier..
😉A.
05/06/2017 at 12:01 PM #34686You can assembly all of your strategies into a bigger file.
“DEFPARAM CumulateOrders = false” will do the hard job!
Of course you may need to name variables in different ways, say, a1s1 or cond1s1 for the first strategy, then a2s1/cond2s1….. a1s2/cond1s2 for the second strategy etc….
You may name a variable StrategyID = 0 when NOT ONMARKET, the set it to any number you want each buy/sell is executed so you know which strategy was triggered.
Example:
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748DEFPARAM CumulateOrders = False //Only 1 trade at a timeIF NOT OnMarket THEN //Make sure you reset this variable to ZERO when not tradingStrategyID = 0ENDIF//-----------------------------------------------------------------------------------------------------------------IF (StrategyID = 0) OR (StrategyID = 1) THEN //Strategy 1s1.... = ........ENDIF//-----------------------------------------------------------------------------------------------------------------IF (StrategyID = 0) OR (StrategyID = 2) THEN //Strategy 2s2Avg = Average[20](close)s2Rsi = Rsi[14]...//************************************************************************// LONG//************************************************************************IF close CROSSES OVER s2Avg THENStrategyID = 2SET TARGET PPROFIT 20SET STOP PLOSS 10BUY nLots CONTRACT AT MARKETENDIF//************************************************************************// SHORT//************************************************************************IF close CROSSES UNDER s2Avg THENStrategyID = 2SET TARGET PPROFIT 20SET STOP PLOSS 10SELLSHORT nLots CONTRACT AT MARKETENDIF....ENDIF//-----------------------------------------------------------------------------------------------------------------IF (StrategyID = 0) OR (StrategyID = 3) THEN //Strategy 3s3.... = .........ENDIF05/06/2017 at 12:14 PM #34690Thanks Roberto, it is a great idea.
However, I agree that this feature (ProOrder strategies that can communicate with each other) is a must to build successful portfolio and use rebalancing method. I already put this idea into my own wish list (and in prorealtime hands) and I’m looking forward to get this feature soon .. or late 🙂
2 users thanked author for this post.
05/08/2017 at 8:39 PM #34861Thank Nicolas
That is important.
Keep us informed about the progress.Cheers,
A.03/07/2019 at 9:18 PM #93104Will this feature be included in version 11? Thanks!
04/23/2019 at 9:44 AM #96977so you know which strategy was triggered.
Maybe coffee not woke brain yet, but when I look in my Auto-Trading window at Running Systems then how would I know which Strategy within a Multi-Strategy Auto-System had triggered the trade?
04/23/2019 at 10:04 AM #96980What you want to achieve is impossible till PRT support communications among strategies themselves and among them and PRT.
This is was intended to assemble multiple strategies into a single one, mainly to overcome bracket margins by IG, you can only tell which strategy entered a trade from within the same code.
1 user thanked author for this post.
04/24/2019 at 10:12 AM #97036you can only tell which strategy entered a trade from within the same code.
I’m still intrigued by this and cannot work out how how when a trade executes and I look in the code how would I know which strategy (out of multi-strategies) had triggered the trade.
You may name a variable StrategyID = 0 when NOT ONMARKET, the set it to any number you want each buy/sell is executed so you know which strategy was triggered.
Only way I can think of would be to also have the code running on Backtest and GRAPH the StrategyID variables and then I could see which StrategyID number had triggered. Is that how to do it Roberto please?
04/24/2019 at 11:46 AM #97040Yes GraHal, that’s exactly what I do.
1 user thanked author for this post.
-
AuthorPosts
Find exclusive trading pro-tools on