Page 7 of 15 FirstFirst ... 56789 ... LastLast
Results 61 to 70 of 143
  39 39 Attachment(s)    

Thread: EMA Cross EA

  1. #61
    Junior Member
    Join Date
    Jan 2009
    Posts
    13

    Default

    Quote Originally Posted by Ralfiery View Post
    Hello Funyoo .

    If i understand this right , then all this adding /removing indi. from this EA is becourse it does not trade fast enough after crossover . Then i got this idea - dont know if itīs
    posible.

    Can EAīs ma. run on say 30 min.TF (or obtional) and then make the open/close on 1 min TF - then trade comes after max 60sec. After crossover. and then wait x candels .before it can trade again.(maybe an all new EA)

    Just an idea .

    Good weekend to all .
    Hello Ralfiery,

    If u look at page 1 of this thread, you'll see a chart of the EA with its 2 EMA's and you'll also see that the time frame is H4. I think it was Voltron who first started getting funyoo to get this EA to work on a 5 min time frame. Maybe Voltron like to scalp markets. That's his privilege.

    You should also notice on the chart on page 1 that the EMA's crossed around the area of 1.4355 for a short position and the market went down to a low of about 1.3425 That's a 930 pip move. Surely many of those pips could be locked in for a profit.

    I'm trading it on a H4 time frame myself, have gotten a demo account starting at $3,000 on 1-09-2009 to $3,579.08 and a trade on currently that is up $210.00 There was almost 2 weeks when the EA didn't trade so I finally moved up from V2.1 to V3.2
    I think the V3.2 only needs a few minor changes but with so many request going in to Funyoo, I'm not wanting to bother him. I'll wait till things quite down some.

    Good trading to all,

    David9

  2. #62

    Default

    Can anyone post the newest statement and the settings please
    Regards

  3. #63
    Member
    Join Date
    Dec 2008
    Location
    Germany
    Posts
    76

    Default Bug at EMA Cross EA

    Hello funyoo,

    i have tested the EMA Cross EA v2. It brings good results. But there is a problem. When the option StopTradingAtTp is true and at a current position isn't hit the tp, then the EA doesn't close the position when the EMA's crossing in other direction. I hope you understand.

    Is it prossible to code the EA in this way: if the tp isn't hit, then the position is closed when EMA's crossing in opposit way?


    Kind Regards

    crissfx

  4. #64
    Administrator funyoo's Avatar
    Join Date
    Sep 2008
    Posts
    7,003

    Default

    Quote Originally Posted by crissfx View Post
    Hello funyoo,

    i have tested the EMA Cross EA v2. It brings good results. But there is a problem. When the option StopTradingAtTp is true and at a current position isn't hit the tp, then the EA doesn't close the position when the EMA's crossing in other direction. I hope you understand.

    Is it prossible to code the EA in this way: if the tp isn't hit, then the position is closed when EMA's crossing in opposit way?


    Kind Regards

    crissfx
    Hi crissfx,

    Try the v3.5, it should be ok.

  5. #65

    Default tf 5 ema cross

    Quote Originally Posted by david9 View Post
    Hello Ralfiery,

    If u look at page 1 of this thread, you'll see a chart of the EA with its 2 EMA's and you'll also see that the time frame is H4. I think it was Voltron who first started getting funyoo to get this EA to work on a 5 min time frame. Maybe Voltron like to scalp markets. That's his privilege.

    You should also notice on the chart on page 1 that the EMA's crossed around the area of 1.4355 for a short position and the market went down to a low of about 1.3425 That's a 930 pip move. Surely many of those pips could be locked in for a profit.

    I'm trading it on a H4 time frame myself, have gotten a demo account starting at $3,000 on 1-09-2009 to $3,579.08 and a trade on currently that is up $210.00 There was almost 2 weeks when the EA didn't trade so I finally moved up from V2.1 to V3.2
    I think the V3.2 only needs a few minor changes but with so many request going in to Funyoo, I'm not wanting to bother him. I'll wait till things quite down some.

    Good trading to all,

    David9
    ---------------------

    hi david

    yes its me who change it to tf 5 min idea, i've been study this ema cross..untill born the latest v35, i've been tested tf4 tf30 tf15 and tf 5, this ea can be used at any tf,

    but the real things of my study is to make it trade without loss, one thing is to find a good filter to replace the dt zigzag lauer, this indi is very good, only its repaint.

    ive found new one, but still in testing, so as for now just wait until im satisfied with this new filter performance.

    ps if trade just try not to trade more then 10p,and use stop at tp

    have a nice day

    to all of you....especially funyoo

  6. #66

    Default Emacross V3.5 Replace Dtzz

    dear Funyoo

    its a long time since the v35, as you said the dt zz is repaint, i'll keep searching for the new one, and at last i've found this 'bbhisto'

    i am quite satisfied with this indi..and i dont think this indi repaint

    i hope,

    can you replace the dt zz lauer with this indi bbhisto,

    TF 1H AND TF 4H - IS THE BEST

    attached below

    P/S just replace the indicator and remains others as usual.
    tq funyoo
    Attached Images Attached Images EMA Cross EA-graph1-jpg 
    Attached Files Attached Files

  7. #67
    Junior Member
    Join Date
    Jan 2009
    Posts
    8

    Default

    dear Funyoo,
    please can you add Magic Number and simple Time filter ( time filter true/false - start time - stop time ) of this version of EMACross ?
    thanks, be patient......

    //+------------------------------------------------------------------+
    //| EMA_CROSS.mq4 |
    //| Coders Guru |
    //| Forex TSD| Metatrader Indicators and Experts Advisors |
    //+------------------------------------------------------------------+

    //+------------------------------------------------------------------+
    //| TODO: Add Money Management routine |
    //+------------------------------------------------------------------+
    //---- input parameters
    extern double TakeProfit=110;
    extern double StopLoss=100;
    extern double TrailingStop=30;
    extern int ShortEma = 1;
    extern int LongEma = 13;
    extern bool UseStopLoss = true;


    extern string S2="---------------- Money Management";

    extern double Lots=0.1;//|-----------------------lots size
    extern bool RiskMM=false;//|---------------------risk management
    extern double RiskPercent=1;//|------------------risk percentage

    //+------------------------------------------------------------------+
    //| expert initialization function |
    //+------------------------------------------------------------------+
    int init()
    {
    //----

    //----
    return(0);
    }
    //+------------------------------------------------------------------+
    //| expert deinitialization function |
    //+------------------------------------------------------------------+
    int deinit()
    {
    //----

    //----
    return(0);
    }

    bool isNewSumbol(string current_symbol)
    {
    //loop through all the opened order and compare the symbols
    int total = OrdersTotal();
    for(int cnt = 0 ; cnt < total ; cnt++)
    {
    OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);
    //Print( "OrderSymbol = " + OrderSymbol() + ": Symbol = " + current_symbol);
    string selected_symbol = OrderSymbol();
    if (current_symbol == selected_symbol)
    return (False);
    }
    return (True);
    }

    int Crossed (double line1 , double line2)
    {
    static int last_direction = 0;
    static int current_direction = 0;

    //Don't work in the first load, wait for the first cross!
    static bool first_time = true;
    if(first_time == true)
    {
    first_time = false;
    return (0);
    }

    if(line1>line2)current_direction = 1; //up
    if(line1<line2)current_direction = 2; //down

    if(last_direction == 0) //first use
    {
    last_direction = current_direction;
    return(0);
    }

    if(current_direction != last_direction) //changed
    {
    last_direction = current_direction;
    return (last_direction);
    }
    else
    {
    return (0); //not changed
    }
    }

    //+------------------------------------------------------------------+
    //| expert start function |
    //+------------------------------------------------------------------+
    int start()
    {
    if(RiskMM)CalculateMM();
    //----

    int cnt, ticket, total;
    double SEma, LEma;


    if(Bars<100)
    {
    Print("bars less than 100");
    return(0);
    }
    if(TakeProfit<10)
    {
    Print("TakeProfit less than 10");
    return(0); // check TakeProfit
    }


    SEma = iMA(NULL,0,ShortEma,0,MODE_EMA,PRICE_CLOSE,0);
    LEma = iMA(NULL,0,LongEma,0,MODE_EMA,PRICE_CLOSE,0);


    static int isCrossed = 0;
    isCrossed = Crossed (LEma,SEma);

    total = OrdersTotal();

    if(total < 1 || isNewSumbol(Symbol()))
    {
    if(isCrossed == 1 )
    {

    if(UseStopLoss)
    ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-StopLoss*Point,Ask+TakeProfit*Point,"EMA_CROSS",12 345,0,Green);
    else
    ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,0,Ask+ TakeProfit*Point,"EMA_CROSS",12345,0,Green);

    if(ticket>0)
    {
    if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES )) Print("BUY order opened : ",OrderOpenPrice());
    }
    else Print("Error opening BUY order : ",GetLastError());
    return(0);
    }
    if(isCrossed == 2)
    {
    if(UseStopLoss)
    ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid+S topLoss*Point,Bid-TakeProfit*Point,"EMA_CROSS",12345,0,Red);
    else
    ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,0,Bid-TakeProfit*Point,"EMA_CROSS",12345,0,Red);

    if(ticket>0)
    {
    if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES )) Print("SELL order opened : ",OrderOpenPrice());
    }
    else Print("Error opening SELL order : ",GetLastError());
    return(0);
    }
    return(0);
    }


    for(cnt=0;cnt<total;cnt++)
    {
    OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);
    //OrderPrint();
    if(OrderType()<=OP_SELL && OrderSymbol()==Symbol())
    {
    if(OrderType()==OP_BUY) // long position is opened
    {
    /*
    // should it be closed?
    if(isCrossed == 2)
    {
    OrderClose(OrderTicket(),OrderLots(),Bid,3,Violet) ; // close position
    return(0); // exit
    }*/

    // check for trailing stop
    if(TrailingStop>0)
    {
    if(Bid-OrderOpenPrice()>Point*TrailingStop)
    {
    if(OrderStopLoss()<Bid-Point*TrailingStop)
    {
    OrderModify(OrderTicket(),OrderOpenPrice(),Bid-Point*TrailingStop,OrderTakeProfit(),0,Green);
    return(0);
    }
    }
    }
    }
    else // go to short position
    {
    /*
    // should it be closed?
    if(isCrossed == 1)
    {
    OrderClose(OrderTicket(),OrderLots(),Ask,3,Violet) ; // close position
    return(0); // exit
    }*/

    // check for trailing stop
    if(TrailingStop>0)
    {
    if((OrderOpenPrice()-Ask)>(Point*TrailingStop))
    {
    if((OrderStopLoss()>(Ask+Point*TrailingStop)) || (OrderStopLoss()==0))
    {
    OrderModify(OrderTicket(),OrderOpenPrice(),Ask+Poi nt*TrailingStop,OrderTakeProfit(),0,Red);
    return(0);
    }
    }
    }
    }
    }
    }
    return(0);
    }
    void CalculateMM()
    {
    double MinLots=MarketInfo(Symbol(),MODE_MINLOT);
    double MaxLots=MarketInfo(Symbol(),MODE_MAXLOT);
    Lots=AccountFreeMargin()/100000*RiskPercent;
    Lots=MathMin(MaxLots,MathMax(MinLots,Lots));
    if(MinLots<0.1)Lots=NormalizeDouble(Lots,2);
    else
    {
    if(MinLots<1)Lots=NormalizeDouble(Lots,1);
    else Lots=NormalizeDouble(Lots,0);
    }
    if(Lots<MinLots)Lots=MinLots;
    if(Lots>MaxLots)Lots=MaxLots;
    return(0);
    }
    //+------------------------------------------------------------------+

  8. #68
    Administrator funyoo's Avatar
    Join Date
    Sep 2008
    Posts
    7,003

    Default

    Quote Originally Posted by tsf View Post
    dear Funyoo,
    please can you add Magic Number and simple Time filter ( time filter true/false - start time - stop time ) of this version of EMACross ?
    thanks, be patient......
    Hi tsf,

    Here it is.
    Attached Files Attached Files

  9. #69

    Default ema v35 replace DTZZ LAUER WITH BBHISTO

    dear Funyoo

    its a long time since the v35, as you said the dt zz is repaint, i'll keep searching for the new one, and at last i've found this 'bbhisto'

    i am quite satisfied with this indi..and i dont think this indi repaint

    i hope,

    can you replace the dt zz lauer with this indi bbhisto,

    TF 1H AND TF 4H - IS THE BEST

    attached GRAPH POST 70

    P/S just replace the dt zz lauer with this BBHISTO indicator and remains others as usual. the last request funyoo pls

    tq funyoo
    Attached Files Attached Files

  10. #70

    Default jiaalberto pls F... OFF

    IF U WANTED TO SEND THIS PORN LINK HERE PLS DONT EVER AGAIN, GO TO SOMEWHERE ELSE, NOT HERE IN THIS FOREX FORUM

Similar Threads

  1. Ea Sma Cross
    By haba in forum Expert advisors backtesting
    Replies: 2
    Last Post: 04-20-2016, 13:50
  2. ADX Cross EA
    By funyoo in forum Expert advisors backtesting
    Replies: 0
    Last Post: 07-29-2010, 21:24
  3. EMA cross only
    By szmvscla in forum Ideas for expert advisors
    Replies: 7
    Last Post: 03-19-2010, 04:11
  4. ST MA Cross EA
    By eforex in forum Ideas for expert advisors
    Replies: 12
    Last Post: 12-01-2009, 00:07
  5. EA 2 cross ema
    By il_valentino_forever in forum Ideas for expert advisors
    Replies: 1
    Last Post: 10-14-2009, 16:10

Tags for this Thread

100, advisor, adx, alpari, analysis, average, backtest, broker, brokers, change, closing, coding, color, crossover, demo, ea works, eur, eurjpy, expert, expert advisor, experts, forex, gbpjpy, guide, heiken ashi, high, how to, indicator, indicators, live, low, macd, magic, magic number, main, manual, martingale, maxorder, metatrader, moving average, mq4, mql, no repaint, profit, profit factor, profitable, programmer, programming, real, repaint, request, robot, rsi, scalp, scalping, scalping ea, signal, signals, simple, sma, stoch, stochastic, stop, stop ea, stoploss, strategy, study, support, system, test, time, trading, trailing, trailingstop, trend, usd

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •