Tuesday 15 October 2013

Belajar Membuat EA Sederhana 38 (terapan indikator IFX_Keltner_Channel III)

Kita sambung deh part sebelumnya http://jumforex.blogspot.com/2013/07/belajar-membuat-ea-sederhana-37-terapan.html

Dibagian sebelumnya sudah di jelaskan tentang model indikator ini. dan juga ada teman yang sudah bikin eanya di part sebelum nya .
Kali saya juga agan share tentang ea yg berdasarkan indikator ini dengan model averaging .

EA ini cococok untuk mengejar rabat !

Tapi jangan lupa Ea ini ada proteksi demonya  | jadi harus dihilangkan dulu

e

gitu deh sementara

 //+------------------------------------------------------------------+
//|                                            Jum+Keltner Chan .mq4 |
//|                                           Copyright 2013, Annura |
//|                                                gifaesa@yahoo.com |
//|                                     http://JumForex.blogspot.com |
//+------------------------------------------------------------------+
#property copyright "JumForex.blogspot.com"
#property link      "Gifaesa@yahoo.com"

extern string Nama_EA               = "Jum+Keltner+Chan";
extern int    TP                    = 11;
extern int    TP_money              = 11;
extern int    SL                    = 20;
extern bool   SL_otomatis           = false;
extern double Lot                   = 0.01;
extern int    Magic                 = 69;
extern int    Mode_Ma               = 0;
extern int    Ma_Pareode            = 10;
extern int    Price_tip             = 5;
extern int    Max_order             = 2;
double pt,SLb,TPb,SLs,TPs;

int init()
  {
   if(Digits==3 || Digits==5) pt=10*Point;   else   pt=Point;
   return(0);
  }
int deinit()
  {
   return(0);
  }
int start()  {lab();
if(!IsDemo()){Alert("hanya untuk demo boss"); return(0);}
  if(TP_money<=man())closeall();
 
      double kfa  = iCustom(Symbol(),0,"IFX_Keltner_Channel",Ma_Pareode,Mode_Ma,Price_tip,0,0);
      double kfm  = iCustom(Symbol(),0,"IFX_Keltner_Channel",Ma_Pareode,Mode_Ma,Price_tip,1,0);
      double kfb  = iCustom(Symbol(),0,"IFX_Keltner_Channel",Ma_Pareode,Mode_Ma,Price_tip,2,0);
      static datetime w;
      if(TP==0)TPb=0;else TPb=Ask+TP*pt;
      if(TP==0)TPs=0;else TPs=Bid-TP*pt;
      if(SL==0)SLb=0;else SLb=Ask-SL*pt;
      if(SL==0)SLs=0;else SLs=Bid+SL*pt;
      if(SL_otomatis){  SLb=kfb; SLs=kfa;}//else if(!SL_otomatis){SLb=Ask-SL*pt; SLs=Bid +SL*pt;}
      if(w!=Time[0] && IsDemo()){
      if(Ask<kfb && JumlahOrder(0)<Max_order)   {
         OrderSend(Symbol(),OP_BUY,Lot,Ask,3,SLb,TPb,Nama_EA,Magic,0,Blue);
      }
      if(Bid>kfa && JumlahOrder(1)<Max_order) {
        OrderSend(Symbol(),OP_SELL,Lot,Bid,3,SLs,TPs,Nama_EA,Magic,0,Red);
          }
      w=Time[0]; }

   return(0);
  }
//+------------------------------------------------------------------+
int JumlahOrder(int Tipe){   int Total = 0;
 for(int i=0; i<OrdersTotal(); i++)   {
 OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
 if(OrderSymbol()!=Symbol() || OrderMagicNumber()!=Magic || OrderType()!=Tipe) continue;
 if(IsDemo())Total++; }
 return(Total);}
double man(){double Total = 0;
 for(int i=0; i<OrdersTotal(); i++)   {
 OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
 if(OrderSymbol()!=Symbol() || OrderMagicNumber()!=Magic ) continue;
 if(IsDemo())Total+=OrderProfit(); }
 return(Total);}
void closeall(){
 for (int i = OrdersTotal() - 1; i >= 0; i--) {
 OrderSelect(i, SELECT_BY_POS, MODE_TRADES);
 if (OrderSymbol() != Symbol() || OrderMagicNumber()!=Magic  ) continue;
 if (OrderType() > 1) OrderDelete(OrderTicket());
 if (OrderType() == 0) OrderClose(OrderTicket(), OrderLots(), Bid, 3, CLR_NONE);
 if (OrderType() == 1)OrderClose(OrderTicket(), OrderLots(), Ask, 3, CLR_NONE); }}
void lab(){
 Comment("\n ",
   "\n ------------------------------------------------",
   "\n :: Spread                 : ", MarketInfo(Symbol(), MODE_SPREAD),
   "\n :: Leverage               : 1 : ", AccountLeverage(),
   "\n :: Equity                 : ", AccountEquity(),
   "\n :: Jam Server             :", Hour(), ":", Minute(),
   "\n ------------------------------------------------",
   "\n :: Total Op Buy  : ",JumlahOrder(0),
   "\n :: Total Op Sell : ",JumlahOrder(1),
   "\n ------------------------------------------------",
   "\n :: >>By: Jum69<<",
   "\n ------------------------------------------------");
}










4 comments:

  1. Are you looking for Best MT4 EA and Automated Forex Software’s? Drive Gold is the one stop solution for Forex Software’s and Forex Robots.
    Gold is known to be the most precious of metals. Gold may be an asset against economical crisis. When the market is declining or in time of inflation, national debt, war and social unrest and in currency failure; gold can be your harbor. In the last decade, a huge rise has been observed in the prices of gold. It has gone up to $1,800 an ounce from around $350. It was in August 2011 that gold prices reached its peak. However, a decline in the prices has been observed in recent weeks. It has declined to $1,600.

    ReplyDelete
  2. Trading of foreign currency or Forex trading as it is known is an easy way to make huge money by investing a small amount. There have been many traders who have, made huge profits by using the expert advice from others who have been on the forex platform for many years. Number of reasons makes Forex market the best place for investors who like their money to grow quickly. The highest daily turnover sure makes the Forex market the best place for any new trader to get accustomed with ups and downs of stock market. To know more about forex signals trading. You visit and join us: forex signals

    ReplyDelete
  3. Forex Trendy is a state of the art program capable of recognizing the safest continuation chart patterns. It scans through all the forex pairs, on all time frames and analyzes every possible breakout.

    ReplyDelete
  4. As claimed by Stanford Medical, It's indeed the SINGLE reason this country's women get to live 10 years more and weigh 19 KG less than us.

    (And really, it has absoloutely NOTHING to do with genetics or some secret-exercise and really, EVERYTHING to do with "how" they eat.)

    P.S, I said "HOW", not "what"...

    Tap on this link to reveal if this little test can help you release your true weight loss possibility

    ReplyDelete