A little help for this strategy that works very well …
Forums › ProRealTime English forum › ProOrder support › A little help for this strategy that works very well …
- This topic has 24 replies, 2 voices, and was last updated 1 year ago by robertogozzi.
-
-
02/23/2017 at 11:04 PM #2625102/23/2017 at 11:09 PM #2625202/23/2017 at 11:38 PM #2625402/23/2017 at 11:41 PM #2625502/24/2017 at 9:24 PM #26305
hi guys back in code ;
juste mix the two codes and it is very close that i want
…… but dont works , dont know why ….. could you help me
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889//-------------------------------------------------------------------------// Code principal : MonSystème(196)//-------------------------------------------------------------------------// Definición de los parámetros del códigoDEFPARAM CumulateOrders = false // Acumulación de posiciones desactivadaDEFPARAM FlatAfter =173000// Órdenes máximasif Ordersize>18 thenOrdersize=18endif// Riesgo, multiplicador de contratos.n=1HoraEntradaLimite = 090600HoraInicio = 090500HoraEntradaLimite1 = 091600HoraInicio1 = 091500HoraEntradaLimite2 = 093100HoraInicio2 = 093000if dayofweek=1 then //Mondaydaytrading=1endifif dayofweek=2 then // Tuesdaydaytrading=1endifif dayofweek=3 then // Wednesdaydaytrading=1endifif dayofweek=4 then //Thursdaydaytrading=1endifif dayofweek=5 then // Frifaydaytrading=1endifif Time >= HoraInicio and time <= HoraEntradaLimite and daytrading= 1 or Time >= HoraInicio1 and time <= HoraEntradaLimite1 and daytrading= 1 or Time >= HoraInicio2 and time <= HoraEntradaLimite2 and daytrading= 1 thenc1 = open < close-2IF c1 THENif not onmarket thenIF PositionPerf(1) < 0 THENOrderSize = OrderSize/2//+1if ordersize<1 thenordersize=1ENDIFELSIF PositionPerf(1) > 0 THENOrderSize =OrderSize+2endifbuy ordersize*n contract AT close+2 stopendifc2= open > close-1IF c2 THENif not onmarket theniF PositionPerf(1) < 0 THENOrderSize = OrderSize/2//+1if ordersize<1 thenordersize=1ENDIFELSIF PositionPerf(1) > 0 THENOrderSize =OrderSize+2ENDIFsellshort ordersize*n contract AT close-1 stopendifendifendifendifSET STOP ptrailing 502/24/2017 at 10:33 PM #2630902/24/2017 at 10:59 PM #2631102/25/2017 at 3:24 PM #2635003/10/2023 at 12:06 AM #21128203/10/2023 at 7:49 AM #211287Only post in the language of the forum that you are posting in. For example English only in the English speaking forums and French only in the French speaking forums.
Thank you 🙂
-
AuthorPosts