View Single Post
  #86 (permalink)  
Old 01-29-2007, 10:16 PM
frantacech's Avatar
frantacech frantacech is offline
Senior Member
 
Join Date: Sep 2006
Posts: 496
frantacech is on a distinguished road
GMACD H4+D1 logic for any Ea

PHP Code:
    //+---------------------------GMACD Logic coded --------------------------
  
    
double macd_H1=iMACD(NULL,PERIOD_H1,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_MAIN,0); 
    
double macd_HH1=iMACD(NULL,PERIOD_H1,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_SIGNAL,0);
    
double macd_H4=iMACD(NULL,PERIOD_H4,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_MAIN,0); 
    
double macd_HH4=iMACD(NULL,PERIOD_H4,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_SIGNAL,0); 
    
double macd_D1=iMACD(NULL,PERIOD_D1,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_MAIN,0); 
    
double macd_DD1=iMACD(NULL,PERIOD_D1,FastEMA,SlowEMA,SignalSMA,PRICE_CLOSE,MODE_SIGNAL,0); 

    
int _h1=0_h4=0_d1=0;
        
    if ((
macd_H1 macd_HH1)) { _h1 1; }
    if ((
macd_H1 macd_HH1)) { _h1 = -1; }
    
    if ((
macd_H4 macd_HH4)) { _h4 1; }
    if ((
macd_H4 macd_HH4)) { _h4 = -1; }
    
    if ((
macd_D1 macd_DD1)) { _d1 1; }
    if ((
macd_D1 macd_DD1)) { _d1 = -1; }
  
    if (
_h4==&& _d1==1) {gmacdbuysignal=truegmacdsellsignal=false;}
    if (
_h4==-&& _d1==-1) {gmacdsellsignal=truegmacdbuysignal=false;}   
  
  
//+---------------------------GMACD Logic -------------------------- 
__________________
RUN With The BULLS And HUNT With The BEARS - Nothing By Chance
Reply With Quote