extern INPUTS: 6 Calculations will be shown in real time on chart: P.Higherthanhigh : 100 P.lowerthanlow : 100 2temaDifinpips : 120(points) DIFtemaFOREXIT : 100(points) DIFtemaFOREXIT_2 : 100(points) pointsforEXIT : 100 (points) pointsforEXI_2 : 100 TP :400 and Stoploss:400 ,Trailing Stop:200 ,Slippage:10. Breakeven:300 XUSD:50 MovingA:14 Base lot:0.01 P.lowerthanlow : 100 (if there is 100 points difference) [TEMAlow -bid price] P.Higherthanhigh : 100 (if there is 100 points difference) [ask price-TEMAhigh] 2temaDifinpips : 120 points (HIGHTEMA -LOWTEMA) DIFtemaFOREXIT = 100 means HIGHTEMA + 100 points if HIGHTEMA =1.30000 DIFtemaFOREXIT = 1.30100 Add this to calculation to Chart in Real Time DIFtemaFOREXIT_2 =100 means LOWTEMA - 100 points if LOWTEMA =1.20100 DIFtemaFOREXIT_2 = 1.20000 Add this to calculation to Chart in Real Time pointsforEXIT = 100 means we want to profit 100 points. So if BUY =1.10000 BUY CLOSE: 1.10100 Add this to calculation to Chart in Real Time pointsforEXIT_2 =100 means we want to profit 100 points. So if SELL =1.10100 SELL CLOSE: 1.10000 Add this to calculation to Chart in Real Time ENTRY RULES --BUY When MA(14) is lower than all tema "AND"if "P.lowerthanlow" bigger than 100 "AND" if 2temaDifinpips is bigger than 120 --SELL When MA(14) is higher than all tema "AND" if "P.Higherthanhigh"ÝS bigger than 100 "AND"if 2temaDifinpips is bigger than 120 EXIT RULES FOR A BUY (There are two rules to close a BUY other than TP,SL,Trailing sl. pls code comment of closings): 1)if price is higher than DIFtemaFOREXIT ,exit (of first priority) "comment: CLOSED BY DIFtemaFOREXIT" 2)if price is higher than one of DIFtemaFOREXIT or pointsforEXIT ,exit. (of second priority) "comment: CLOSED BY pointsforEXIT" 3)TP :400 "comment: CLOSED BY TP " 4)Stoploss:400 "comment: CLOSED BY Stoploss" 5)Trailing Stop:200 "comment: CLOSED BY Trailing Stop"" EXIT RULES FOR A SELL (There are two rules to close a SELL): 1)if price is lower than DIFtemaFOREXIT_2 ,so exit (of first priority) "comment: CLOSED BY DIFtemaFOREXIT_2 " 2)if price is lower than one of DIFtemaFOREXIT_2 or pointsforEXIT_2 . ...secondarily priority "comment: CLOSED BY pointsforEXIT_2 " 3)TP :400 "comment: CLOSED BY TP " 4)Stoploss:400 "comment: CLOSED BY Stoploss" 5)Trailing Stop:200 "comment: CLOSED BY Trailing Stop"" Lot Sizing: Add 0.01 lot the Lotsize after every XUSD (look above 50 USD) growth of accountbalance Decrease 0.01 lot from the Lotsize after every XUSD decrease of accountbalance.