This is a mean reverting strategy that I currently run live on AUDCAD, on a 1 hour timeframe.
It is based on Bollinger Bands piercing and accumulation of same direction candlesticks in a single row.
WalkForward analysis attached.
Enjoy, comment and improve 🙂
Discussions about the strategy in the automatic trading forum: https://www.prorealcode.com/topic/reverting-strategy-audcad-h1-timeframe/
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
//------------------------------------------------------------------------- // Main code : audcad_meanrevert_v2 //------------------------------------------------------------------------- defparam cumulateorders = false n = 1 m = 3 l = 90 cs= summation[n](close>open) = n cs = cs and close>bollingerup[20](close) and close>dlow(2) cl= summation[m](close<open) = m cl = cl and close<bollingerdown[20](close) and close<Dhigh(2) size = 2 //entry conditions if cs then sellshort size contract at market endif if cl then buy size contract at market endif //exit conditions if shortonmarket and close<average[l](close) then exitshort at market endif if longonmarket and close>average[l](close) then sell at market endif |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Hi.
Please, describe the algorithm in words. I want to understand how it works, but for now I do not know this programming language. Thank you.