New to PRT and coding but not to trading
Forums › ProRealTime English forum › Welcome new members › New to PRT and coding but not to trading
- This topic has 5 replies, 2 voices, and was last updated 7 years ago by Gmanicus.
-
-
05/10/2017 at 8:01 PM #35114
Hello everyone
Ive been off sick from work for a few weeks and decided to tinker with my old trading accounts again. To my surprise I was doing pretty well Intraday trading the FTSE 100 on the 5 minute period.
However I can’t stay sick forever so I thought I’d open a prt account from my IGindex account and have a go at automating my strategy. But……sweet mother of god I no longer know the woods from the trees! I’ve only been using their simple, wisiwig, version but it’s proving too hard to understand if I am accurately reflecting my trading strategy on prt. I have a feeling I’m not and get distracted by backtesting stochastic strategies, listening to 6 music, checking my emails and wondering how many cups of tea it’s possible to drink in one day.
Any how, what I’m after is some help. I’m happy to explain my strategy if you guys can code it and maybe with the community advice and tweaking we can come up with something worth having.
Looking forward to the brainathon!
graham
05/10/2017 at 11:06 PM #3513905/11/2017 at 8:14 AM #35149Hi Stanton
Thanks for the welcome and for the offer of help. Im not really sure where best to post my strategy for now so will post it here and take your lead as to where best to post it.
So, my strategy is this.
Instrument: FTSE100 (5 minute period)
Indicators: Bollinger (20,2), EMA(26), EMA(14), EMA(6), CCI(14) and Stochastic(14,3,3)
Strategy: Basically the strategy is follows the price action over the mid bollinger line and the trade is placed after the first price to cross the mid bollinger line open and closes either above or below it.
Rules for long trades: 1. CCI moving upwards crossing 0 and or between 0 and 100. 2. Stochastic moving upwards crossing 40 and or between 40 and 80 (preferably previous 3 periods showing the K line crossing over the D line and remaining above it in the current period.). 3. A previous alignment of Mid Bol below 26 EMA, 14 EMA below Mid Bol and 6 EMA below 14 EMA. 4. 1st period price action open and close below Mid Bol, 2nd period price action open below Mid Bol and Close above, 3rd period price action opens and close above the Mid Bol – Close triggers the trade. (the 2nd period doesn’t have to span the Mid Bol as long as there is a strong movement up towards the mid bol and the next period price action opens and closes above the mid bol.)
Rules for short trades: Reverse above 🙂
I do use a more simplistic version whereby i just pay attention to the price action, mid bol and the stochastic.
Stop: 10
Target: 8 ( It is possible to get much more out of the movement than this but my greedy desires have often left me counting my loses so i tend to stick to 8)
Time: Because of the spreads and volatility i only trade between the FTSE opening times – 08:00 to 16:30
Ok, so that is the jist of it and i hope its clear enough to code from. Any way i would appreciate your thoughts and feelings!
All the best
Graham
05/11/2017 at 7:27 PM #35236Hi Graham
Took a stab at it results are not great maybe you can see if i went wrong somewhere.
11234567891011121314151617181920212223242526272829303132333435363738icci=CCI[14](typicalPrice)midband = Average[20](close)stochrsi = Stochastic[14,3](Close)ema26 = ExponentialAverage[26](close)ema14 = ExponentialAverage[14](close)ema6 = ExponentialAverage[6](close)c1 = icci crosses over 0c2 = stochrsi crosses over 40c3 = ema26 > midbandc4 = ema14 < midbandc5 = ema14 > ema6c6 = open[2] < midband and close[2] < midband and open[1] < midband and close[1]> midband and open > midband and close > midbandLongConditions = c1 and c2 and c3 and c4 and c5 and c6IF NOT LongOnMarket AND LongConditions THENBUY 1 CONTRACTS AT MARKETENDIFc7 = icci crosses under 0c8 = stochrsi crosses under 40c9 = ema26 < midbandc10 = ema14 > midbandc11 = ema14 < ema6c12 = open[2] > midband and close[2] > midband and open[1] > midband and close[1] < midband and open < midband and close < midbandShortConditions = c7 and c8 and c9 and c10 and c11 and c12//// Conditions to enter short positionsIF NOT ShortOnMarket AND ShortConditions THENSELLSHORT 1 CONTRACTS AT MARKETENDIFset stop ploss 10set target pprofit 8105/11/2017 at 8:17 PM #35241Added date range
12345678910111213141516171819202122232425262728293031323334353637383940414243DEFPARAM CumulateOrders = FalseDEFPARAM FLATBEFORE = 080000DEFPARAM FLATAFTER = 163000icci=CCI[14](typicalPrice)midband = Average[20](close)stochrsi = Stochastic[14,3](Close)ema26 = ExponentialAverage[26](close)ema14 = ExponentialAverage[14](close)ema6 = ExponentialAverage[6](close)c1 = icci crosses over 0c2 = stochrsi crosses over 40c3 = ema26 > midbandc4 = ema14 < midbandc5 = ema14 > ema6c6 = open[2] < midband and close[2] < midband and open[1] < midband and close[1]> midband and open > midband and close > midbandLongConditions = c1 and c2 and c3 and c4 and c5 and c6IF NOT LongOnMarket AND LongConditions THENBUY 1 CONTRACTS AT MARKETENDIFc7 = icci crosses under 0c8 = stochrsi crosses under 40c9 = ema26 < midbandc10 = ema14 > midbandc11 = ema14 < ema6c12 = open[2] > midband and close[2] > midband and open[1] > midband and close[1] < midband and open < midband and close < midbandShortConditions = c7 and c8 and c9 and c10 and c11 and c12//// Conditions to enter short positionsIF NOT ShortOnMarket AND ShortConditions THENSELLSHORT 1 CONTRACTS AT MARKETENDIFset stop ploss 10set target pprofit 805/11/2017 at 10:14 PM #35257 -
AuthorPosts
Find exclusive trading pro-tools on