Random 1min EURUSD Scalper
Forums › ProRealTime English forum › ProOrder support › Random 1min EURUSD Scalper
- This topic has 40 replies, 8 voices, and was last updated 6 years ago by Vonasi.
-
-
02/05/2018 at 1:37 PM #61531
This scalping strategy is based on the concept of following a coin flip randomized approach to picking market direction and then simply managing the trade according to a Risk:Reward ratio of 1:2. The strategy also has equity curve management built-in to help optimize performance.
The direction of the trade is randomly determined based on the fact that at any given point the direction of a candle will be either be red or green. The algorithm used will pick an historic candle between 1 and 5 bars back and use this as a binary coin flip to determine direction.
Stoploss distance is determined dynamically through the use of a smoothed ATR and Take Profit is simply twice the Stoploss distance.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758DEFPARAM CUMULATEORDERS = FALSECurvePeriod = 90Type = 0Capital = 10000Equity = Capital + StrategyProfitEquityCurve = Average[CurvePeriod,Type](Equity)If hour >= 9 and hour <= 22 Thenpossize = 1Elsepossize = 0If longonmarket ThenSell at marketElsIf shortonmarket ThenExitshort at marketEndIfEndIfonce RX = 1once SV = 1If RX > 5 ThenIf SV > 5 ThenSV = 2EndIfRX = RX-SVIf RX <=0 ThenSV = 2EndIfElseRX = RX + 2SV = SV + 1EndIfonce dir = 0If dir = 0 and close[RX] > open[RX] Thendir = 1ElsIf dir = 1 and close[RX] < open[RX] Thendir = 0EndIf//GRAPH RX coloured(255,0,0) AS "RX"//GRAPH SV coloured(255,0,255) AS "SV"//GRAPH DIR AS "DIR"If countofposition = 0 and (barindex < curveperiod or (barindex > curveperiod and equity >= equitycurve)) and dir = 0 ThenBuy possize contract at marketElsIf countofposition = 0 and (barindex < curveperiod or (barindex > curveperiod and equity >= equitycurve)) and dir = 1 ThenSellshort possize contract at marketEndIfSL = ((average[20](range)+1.2*STD[20](range))*100000)SET STOP pLOSS SL*possizeSET TARGET pPROFIT SL*2*possize1 user thanked author for this post.
02/05/2018 at 1:42 PM #6155302/05/2018 at 1:50 PM #6155602/06/2018 at 5:59 AM #61623@Nicolas or it could be due to our time zone difference, so you can try changing line 10 to:
If hour >= 8 and hour <= 21 Then
But can’t think it would have such large effect. The strategy if adjusted for timezone differences is profitable on multiple markets that I have tested.
02/06/2018 at 6:59 AM #61627This concept interesting, what is your opinions about: trend is your friend, follow the SMA200 , bla bla Bla?
can you please post a pic of the values RX and SV, why you are saying is random? Looks pretty deterministic for me.
In your fuction for ATR, you can use the function “pipsize”
Cheers
02/06/2018 at 8:02 AM #6163202/06/2018 at 11:25 AM #61662@Leo, yes I do believe trading with the 200SMA is a good idea athough for this specific strategy I did not want to add a trend bias. I consider the trade direction random, because if you GRAPH DIR you will not see any recognizable pattern.
@Nicolas, I cannot understand your result. I tested with a spread of 0.8, maybe see if that makes the difference.Attached is the exact same algorithm on the AUDUSD tested with a spread of 1 and trading time of 2-19 (GMT), you need to adjust for GMT+1
02/06/2018 at 1:51 PM #6168602/06/2018 at 2:00 PM #6169102/06/2018 at 2:01 PM #61694I realize now that because the direction is technically random the result will never be exactly the same as the starting point is always different.
Yet the results should still not differ much. Will back test in my demo account to see if there is a difference.
02/06/2018 at 6:52 PM #6176402/09/2018 at 2:13 PM #62125I am not at home at the moment, but I still thinking in your concept @juanj. Many authors can be agreed that invest in finantial markets is like flipping a coin.
Therefore, try the same with some bias or another conditions,
-momentum Like: ” close[RX] > Close”
– a filter like for entry long, price should be avobe a parabolic SAR.
Did you try another reward ratio like 1.5 or 3 ?
Cheers
02/10/2018 at 6:59 AM #6218202/10/2018 at 9:56 AM #62184Hi,
I tried several things but still not being profitable.
I tried: parabolic SAR and momentum and pending ordes
Hope you get some other ideas
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071DEFPARAM CUMULATEORDERS = FALSEDEFPARAM PreLoadBars = 10000possize=1once RX = 1once SV = 1If RX > 5 ThenIf SV > 5 ThenSV = 2EndIfRX = RX-SVIf RX <=0 ThenSV = 2EndIfElseRX = RX + 2SV = SV + 1EndIfdir = 0if not onmarket and hour >= 7 and hour <= 21 thenIf close[RX] > open[RX] Thendir = 1ELSEdir = -1EndIfENDIF//GRAPH RX coloured(255,0,0) AS "RX"//GRAPH SV coloured(255,0,255) AS "SV"//GRAPH DIR AS "DIR"SL = average[20](range)+2*STD[20](range)SL = SL/pipsizeMySAR= SAR[0.02,0.02,0.2]If not longonmarket and dir = 1 and close > mySAR and close>close[RX] ThenBuy possize contract at high+2*pipsize stopSET STOP pLOSS SLSET TARGET pPROFIT 3*SLENDIFIf not shortonmarket and dir = -1 and close <mySAR and close<close[RX] ThenSellshort possize contract at low-2*pipsize stopSET STOP pLOSS SLSET TARGET pPROFIT 3*SLEndIfIf longonmarket Thenif hour <= 7 or hour >= 22 ThenSell at marketENDIFIf close crosses under mySAR thenSell at marketENDIFENDIFIf shortonmarket Thenif hour <= 7 or hour >= 22 ThenExitshort at marketEndIfIf close crosses over mySAR thenSell at marketENDIFEndIf02/10/2018 at 10:09 AM #62185Hi,
I just studied this strategy whose concept is very interesting.
However, it is not profitable such as with a TF 1min on a full day.
So I set up a trading limit and go out every day with a gain.
To optimize the number of trades per day, I’m spending on an 18s TF.
The results are positive over a period of 20,000 units (impossible to go beyond, with a TF of 18s there is no more history)I give you my version below. I look forward to your comments.
-
AuthorPosts
Find exclusive trading pro-tools on