Forex



Go Back   Forex Trading > Trading systems > Ema Cross
Forex Forum Register More recent Blogs Calendar Advertising Others Help






Register
Welcome to Forex-TSD!, one of the largest Forex forums worldwide, where you will be able to find the most complete and reliable Forex information imaginable.

From the list below, select the forum that you want to visit and register to post, as many times you want. It’s absolutely free. Click here for registering on Forex-TSD.

Exclusive Forum
The Exclusive Forum is the only paid section. Once you subscribe, you will get free access to real cutting-edge Trading Systems (automated and not), Indicators, Signals, Articles, etc., that will help and guide you, in ways that you could only imagine, with your Forex trading.
  • Elite Section
    Get access to private discussions, specialized support, indicators and trading systems reported every week.
  • Advanced Elite Section
    For professional traders, trading system developers and any other member who may need to use and/or convert, the most cutting-edge exclusive indicators and trading systems for MT4 and MT5.
See more

View Poll Results: What do you think about Counter-Trend strategies?
They are good. 233 30.62%
They are bad. 122 16.03%
Good strategies! But have to be well programmed. 269 35.35%
I don’t know what you are talking about. 154 20.24%
Multiple Choice Poll. Voters: 761. You may not vote on this poll

Reply
 
Thread Tools Display Modes
  #751 (permalink)  
Old 05-18-2009, 11:33 AM
cja's Avatar
cja cja is offline
Senior Member
 
Join Date: Apr 2006
Posts: 676
cja is on a distinguished road
code issue

Quote:
Originally Posted by camisa View Post
Can someone help me out? Should be pretty straightforward...

Sometimes an arrow appears and then disappear...

fasterEMAnow = iMA(NULL, 0, FasterEMA, 0, MODE_EMA, PRICE_CLOSE, i);
fasterEMAprevious = iMA(NULL, 0, FasterEMA, 0, MODE_EMA, PRICE_CLOSE, i+1);
fasterEMAafter = iMA(NULL, 0, FasterEMA, 0, MODE_EMA, PRICE_CLOSE, i-1);
slowerEMAnow = iMA(NULL, 0, SlowerEMA, 0, MODE_EMA, PRICE_OPEN, i);
slowerEMAprevious = iMA(NULL, 0, SlowerEMA, 0, MODE_EMA, PRICE_OPEN, i+1);
slowerEMAafter = iMA(NULL, 0, SlowerEMA, 0, MODE_EMA, PRICE_OPEN, i-1);

Change PRICE_OPEN to PRICE_CLOSE that should help the repaint issue.
__________________
My Disadvantage is that I am not a Trained Programmer - My Advantage is that I am not a Trained Programmer.
http://cjatradingtools.com/
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #752 (permalink)  
Old 05-20-2009, 12:04 PM
Senior Member
 
Join Date: Apr 2009
Posts: 130
Petor is on a distinguished road
Petor

Quote:
Originally Posted by codersguru View Post
This even better:

TakeProfit: 130
Lots: 1
TrailingStop: 20
TimeFrame: Daily
Hello, Master CodersGuru! I'm new Trader-Student, and not speek MQL4- and English-Languages. Plese You for help my! I like to find one Function, for: "Close All Positions of exactly fixed Price". Thank You, very much, for The Programs, thet You are publish release! Thank You!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #753 (permalink)  
Old 07-11-2009, 03:51 PM
Junior Member
 
Join Date: May 2009
Posts: 5
Jenks09 is on a distinguished road
How do I avoid being whipsawed?

Hi,

I'm writing a basic EA that initiates a trade based on the 8 and 13 EMA crossing on H1.

When I backtest this I see that during certain periods, the lines crossover and re-crossover giving false signals...basically price is trading up and down in a tight range and causing the crossover signals to fire.

As you know, the MA crossover works best in a trending market, not when it's bobbling up and down and not going anywhere.

See attached chart for an example of what I mean...between the blue vertical lines I have marked 5 'X' spots where the lines crossover.

Is there any indicator I can use to add to the existing EA MA crossover signals system to prevent entering a trade during times when price is whipsawing up and down. How can I 'programmatically' tell when not to enter a trade during these conditions?

Cheers,
Jenks.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #754 (permalink)  
Old 07-20-2009, 08:33 AM
Junior Member
 
Join Date: Jun 2009
Posts: 1
seyhans is on a distinguished road
what if electricity problem?

Hi all,

Will this EA(EMA_CROSSmod.mq4) recognize if a trade has not been closed while the computer was turned off because of an electricity outage or internet connection problem in my area? And will it be able to resume the same trade?

Regards,
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #755 (permalink)  
Old 07-21-2009, 06:08 PM
Junior Member
 
Join Date: Jul 2009
Posts: 2
rg144 is on a distinguished road
HELP!!! Trying to play custom alert sound!

Hi guys,

i downloaded a simple Moving Average Price Alert here some time ago.

Unfortunately i'm having trouble getting the alert to play a custom sound (i.e i cannot choose my own wav sound file); the indicator simply keeps defaulting to the standard alert.wav file in the MT4 sounds folder..

can anyone help??!? im going crazy, cant seem to figure out whats wrong with the code!!

code below (and attached)

Code:
//+------------------------------------------------------------------+
//|                                     EMA-alert-Symbol-Period.mq4  |
//|                      Copyright © 2007, MetaQuotes Software Corp. |
//|                                        http://www.metaquotes.net |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2007, MetaQuotes Software Corp."
#property link "http://www.metaquotes.net"

#property indicator_chart_window
#property indicator_buffers 1

//MODE_SMA 0 Simple moving average, 
//MODE_EMA 1 Exponential moving average, 
//MODE_SMMA 2 Smoothed moving average, 
//MODE_LWMA 3 Linear weighted moving average. 

//PRICE_CLOSE 0 Close price. 
//PRICE_OPEN 1 Open price. 
//PRICE_HIGH 2 High price. 
//PRICE_LOW 3 Low price. 
//PRICE_MEDIAN 4 Median price, (high+low)/2. 
//PRICE_TYPICAL 5 Typical price, (high+low+close)/3. 
//PRICE_WEIGHTED 6 Weighted close price, (high+low+close+close)/4. 


//---- input parameters
extern int ma_period = 24;
extern int ma_mode   = 0;
extern int ma_price  = 0;
extern int ma_shift  = 0;
//---- buffers
double ExtMapBuffer1[];
extern bool Box_Alert    =true;
extern bool Sound_Alert  =true;
extern string Sound_File = "timeout.wav";   //<-- i've changed this to "timeout.wav" yet it still plays alert.wav!!!?????
extern bool Email_Alert  =false;
extern int pip_distance  = 100;
datetime lastimealert;
//----
double ema_value;
  
//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
//---- indicators
  
    SetIndexBuffer(0, ExtMapBuffer1);

//---- name for DataWindow and indicator subwindow label
  
//----
   
    return(0);
  }
//+------------------------------------------------------------------+
//| Custor indicator deinitialization function                       |
//+------------------------------------------------------------------+
int deinit()
  {
//----
    return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator iteration function                              |
//+------------------------------------------------------------------+
int start()
  {
    int limit;
    int counted_bars = IndicatorCounted();
//---- check for possible errors
    if(counted_bars < 0) 
        return(-1);
//---- last counted bar will be recounted
    if(counted_bars > 0) 
        counted_bars--;
    limit = Bars - counted_bars;
//----
   
   string MA;
   
   
    for(int i = 0; i < limit; i++)
      {
       ema_value= iMA(NULL,0,ma_period,ma_shift,ma_mode,ma_price,i);
       
       if(ma_mode==0){MA="SMA";}
       if(ma_mode==1){MA="EMA";}
       if(ma_mode==2){MA="SMMA";}
       if(ma_mode==3){MA="LWMA";}
        //----
        ExtMapBuffer1[i] = ema_value-Ask ;
        if(MathAbs(ema_value-Bid)<=pip_distance*Point&& lastimealert!= Time[0] )
            {
            
            if(Box_Alert) Alert(Symbol()," M",Period()," Price is within ",pip_distance," pips of ",ma_period," Period "+MA+"");
            if(Sound_Alert) PlaySound(Sound_File);
            if(Email_Alert) SendMail("Price Alert on "+Symbol()+" M"+Period(),Symbol()+" M"+Period()+" Price is within "+pip_distance+" pips of "+ma_period+" Period "+MA+"");
            lastimealert= Time[0];
            }
            
        }


//----
    return(0);
  }
//+------------------------------------------------------------------+
Attached Files
File Type: mq4 MA-Price-Alert.mq4 (3.5 KB, 44 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #756 (permalink)  
Old 08-20-2009, 03:21 PM
davydevaux's Avatar
Member
 
Join Date: Jul 2009
Posts: 56
davydevaux is on a distinguished road
could someone change the ema cross EA to work with JMA line ???

i did some visual back tests and it looks realy good
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #757 (permalink)  
Old 08-20-2009, 03:22 PM
davydevaux's Avatar
Member
 
Join Date: Jul 2009
Posts: 56
davydevaux is on a distinguished road
heres the line i was talking about in the post above.....

i attached it
Attached Files
File Type: mq4 JMA.mq4 (10.7 KB, 56 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #758 (permalink)  
Old 10-08-2009, 11:06 AM
Junior Member
 
Join Date: Dec 2008
Posts: 8
betscafe is on a distinguished road
Thumbs up EMA Cross EA With Retrace Entry

Hi

I been looking for an EA that can follow this system. But so far
without any success. So let me explain how it works and it sure
works very well.

Pair: GBPUSD
Time: H1

EMA: 7
EMA: 14

SELL:

7 moves below 14. No wait for at least 1 candlestick to be below the cross
where high low price is clear of the EMA's. Can't touch. Upon next retrace,

and price at least break any of the EMA with 1 pip. We enter short.

The filter here is the clear candlestick. Stop Loss is 100 pips and take
profit is 100 pips. BUT when 50 pips has been gained move stop loss to
break even (Entry price). Or activate trailing SL 25 pips.




Buy:

7 moves above 14. No wait for at least 1 candlestick to be above the cross
where high low price is clear of the EMA's. Can't touch. Upon next retrace and price at least break any of the EMA with 1 pip. We enter long.

The filter here is the clear candlestick. Stop Loss is 100 pips and take
profit is 100 pips. BUT when 50 pips has been gained move stop loss to
break even (Entry price). Or activate trailing SL 25 pips.



When EMA whipsaw there is normally no clear candle. A filter
who with x pips between EMA lines would be good as well. But
is not required.

Is there any EA available like this or can anyone code it?

Thanks,

Daniel
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #759 (permalink)  
Old 11-04-2009, 12:54 PM
Junior Member
 
Join Date: Oct 2009
Posts: 5
marandy is on a distinguished road
Sorry for me English..

I try several experts (mq4) EMA which I download from this forum but I have always the same results.. There are good but when I see Open chart, sometimes I see another order (for example when ShortEma(10)<LongEma(90) is realized BUY order, not SELL).
I don t know where is problem because I tried to simulate a lot of experts and always the same results. Experts usually work correctly but I always see some mistakes.

Marandy
Attached Images
File Type: jpg bez_názvu.JPG (90.5 KB, 0 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #760 (permalink)  
Old 11-08-2009, 10:15 PM
stevewide's Avatar
Junior Member
 
Join Date: Sep 2006
Posts: 15
stevewide is on a distinguished road
Quote:
Originally Posted by betscafe View Post
Hi

I been looking for an EA that can follow this system. But so far
without any success. So let me explain how it works and it sure
works very well.

Pair: GBPUSD
Time: H1

EMA: 7
EMA: 14

SELL:

7 moves below 14. No wait for at least 1 candlestick to be below the cross
where high low price is clear of the EMA's. Can't touch. Upon next retrace,

and price at least break any of the EMA with 1 pip. We enter short.

The filter here is the clear candlestick. Stop Loss is 100 pips and take
profit is 100 pips. BUT when 50 pips has been gained move stop loss to
break even (Entry price). Or activate trailing SL 25 pips.




Buy:

7 moves above 14. No wait for at least 1 candlestick to be above the cross
where high low price is clear of the EMA's. Can't touch. Upon next retrace and price at least break any of the EMA with 1 pip. We enter long.

The filter here is the clear candlestick. Stop Loss is 100 pips and take
profit is 100 pips. BUT when 50 pips has been gained move stop loss to
break even (Entry price). Or activate trailing SL 25 pips.



When EMA whipsaw there is normally no clear candle. A filter
who with x pips between EMA lines would be good as well. But
is not required.

Is there any EA available like this or can anyone code it?

Thanks,

Daniel
Hi Daniel:

Thank you for posting this entry method.

From brief backtesting I can't find much use for the 14ema at entry. Seems the candle always pulls away from the 7 with no need for the 14ema. However, the 14e may help with deciding to stay in the trade.

I know a professional who scalps similar to this entering when price breaks beyond the pulled away candle and stays in as long as next candles are pulled away from the ema.

Steve
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
Reply

Bookmarks

Tags
ANG3110@latchess.com, coders guru ema cross, Cross, cross ema, cross forex, ema 34, ema cross, ema cross ea, ema cross expert, ema cross expert advisor, ema cross indicator, ema cross signal, ema ea, ema forex, EMACross3, ema_cross_2, forex, forex EMA, forex ema cross, forex ema cross ea, forex ema ea, Sidus, universalmacross


Currently Active Users Viewing This Thread: 2 (1 members and 1 guests)
jrous
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cross! creative Indicators - Metatrader 4 191 11-15-2009 04:51 PM
3 MA cross demontaz Indicators - Metatrader 4 3 09-21-2009 06:36 PM
MA cross/Price cross MA EA Pipsta_UK Expert Advisors - Metatrader 4 5 05-10-2007 09:50 PM
ema cross 1f4 General Discussion 5 05-21-2006 04:13 PM


All times are GMT. The time now is 07:20 PM.



Search Engine Friendly URLs by vBSEO 3.2.0 ©2008, Crawlability, Inc.