budget & Timeframe for autom. strategy
Forums › ProRealTime English forum › ProOrder support › budget & Timeframe for autom. strategy
- This topic has 8 replies, 5 voices, and was last updated 8 years ago by Leon.
-
-
08/09/2016 at 6:40 PM #11417
Hello,
i don’t want the system to hold positions over night and i found this code:
DEFPARAM FlatAfter = HHMMSS
for exammple:
DEFPARAM FlatAfter = 200000
but how to make sure that it will start again tomorrow morning at 08:00 o clock?
Another point i am thinking of:
Is there a possibility to code that the system shall just trade till max. 1,000.00€ lost under start budget ?
I want to make sure that it wont use all of the money that is available.
Appreciate every help here!
Best Regards
Leon
08/09/2016 at 6:58 PM #11443Use flatbefore and flatafter. It will only trade between those hours. Regarding your second question, I’m not sure what you mean? Is it stop loss you are talking about? If yes then: Set stop $loss 1000
Hope it helps.
08/09/2016 at 7:16 PM #11444Hi,
thanks for the respond! I will handle the trimeframe as you said.
To specify my second question:
I mean if my trading account is about 10,000.00 €. And i want to limit the strategy to, in case all goes wrong, stop render after using max 1,000.00€ from the account.
Is there a way to code that?
08/09/2016 at 8:44 PM #1145908/09/2016 at 8:48 PM #1146008/22/2016 at 1:22 PM #1203708/22/2016 at 2:42 PM #12043Hi Leon,
You can use STRATEGYPROFIT and test if it returns a value below your allowed loss limit:
123456789if STRATEGYPROFIT <-1000 thennotrade = 1elsenotrade = 0endifif notrade=0 and BUYcondition thenBUY 1 CONTRACT AT MARKETendif08/22/2016 at 6:24 PM #12066Why wouldn’t use the programmed Quit function instead?
123<span class="token keyword">if</span> <span class="token keyword">STRATEGYPROFIT</span> <span class="token operator"><</span><span class="token operator">-</span><span class="token number">1000</span> <span class="token keyword">then</span>QUITendif08/22/2016 at 6:47 PM #12067 -
AuthorPosts
Find exclusive trading pro-tools on