if (NumberStrategy==1)
{
int RSIperiod=14;
int EMA1period=14;
int EMA1ma_shift=0;
int EMA2period=6;
int EMA2ma_shift=0;
int EMA3period=4;
int EMA3ma_shift=0;
int applied_price=0;
double RSI1=iRSI(Symbol(),0,RSIperiod,applied_price,1);
double RSI2=iRSI(Symbol(),0,RSIperiod,applied_price,2);
double RSI3=iRSI(Symbol(),0,RSIperiod,applied_price,3);
double EMA1_1= iMA(Symbol(),0,EMA1period,EMA1ma_shift,MODE_EMA,applied_price,1);
double EMA2_1= iMA(Symbol(),0,EMA2period,EMA2ma_shift,MODE_EMA,applied_price,1);
double EMA3_1= iMA(Symbol(),0,EMA3period,EMA3ma_shift,MODE_EMA,applied_price,1);
double EMA1_2= iMA(Symbol(),0,EMA1period,EMA1ma_shift,MODE_EMA,applied_price,2);
double EMA2_2= iMA(Symbol(),0,EMA2period,EMA2ma_shift,MODE_EMA,applied_price,2);
double EMA3_2= iMA(Symbol(),0,EMA3period,EMA3ma_shift,MODE_EMA,applied_price,2);
if( ((RSI2<50&&RSI1>50) ||(RSI3<50&&RSI2>50)) &&EMA3_1>EMA2_1 && EMA2_1>EMA1_1 ){Signal=1; }
if( ((RSI2>50&&RSI1<50) ||(RSI3>50&&RSI2<50)) &&EMA3_1<EMA2_1 && EMA2_1<EMA1_1 ){Signal=2; }
return(Signal);
}