Comparaison des fichiers tst1.txt et TST2.TXT
***** tst1.txt
double ExtOpenBuffer[], ExtCloseBuffer[]/*, ExtLowHighBuffer[], ExtHighLowBuffer[]*/, haOpen, haClose, haHigh, haLow, Exp_Ind[100][21];
bool Buy, Sell, t_Rsi515=false, t_Adx=false, t_Send=false, t_exp, t_exp2, t_exp3, t_exp4, t_box, t_box2, t_box3=false, t_CPClos
***** TST2.TXT
double ExtOpenBuffer[], ExtCloseBuffer[]/*, ExtLowHighBuffer[], ExtHighLowBuffer[]*/, haOpen, haClose, haHigh, haLow, Exp_Ind[100][21], Exp_Ind2[3][3], Exp_Ind3[3][3];
bool Buy, Sell, t_Rsi515=false, t_Adx=false, t_Send=false, t_exp, t_exp2, t_exp3, t_exp4, t_box, t_box2, t_box3=false, t_CPClos
*****

***** tst1.txt
int option=Option_Signaux, nBars=500, ticket=0, t_cpt, ticket_;      string namBox;
datetime CP_tims[6], tim_exp, tim_ex2, tim_box, t_BxClo=0, tim_BH;      //s[50][2];

***** TST2.TXT
int option=Option_Signaux, nBars=500, ticket=0, t_cpt, ticket_;      string namBox;
datetime CP_tims[6], tim_exp, tim_ex2, tim_box, t_BxClo=0;       //s[50][2];

*****

***** tst1.txt
Digits()) + " - " + TimeToStr(CP_tim, TIME_DATE|TIME_MINUTES) + " ***"); } }
            bool tst1=OrderProfit() < -1.0 * fabs(OrderStopLoss() - OrderOpenPrice())/TS*TV * 0.0025, tst3=(Sell && OrderStopLoss() >
               iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, 48, iBarShift(NULL, 0, OrderOpenTime()))) + 22 * Point()) || (Buy && OrderStopLoss() <
               iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, 48, iBarShift(NULL, 0, OrderOpenTime()))) - 22 * Point());
            tst2 = OrderProfit() < -1.0 * fabs((Sell?iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, 48, iBarShift(NULL, 0, OrderOpenTime()))):
            iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, 48, iBarShift(NULL, 0, OrderOpenTime())))) - OrderOpenPrice())/TS*TV * 0.003;
            if (((tst3 && tst2) || (! tst3 && tst1 && tst2)) && f_wBars(OrderOpenTime(), TimeCurrent()) > 24 * 60/Period()) tim_BH = TimeCurrent();
            t_BH = (t_BH? t_BH: (t_BH2=(((tst3 && tst2) || (! tst3 && tst1 && tst2)) && f_wBars(OrderOpenTime(), TimeCurrent()) > 24 * 60/Period()))); } }
      else if (TimeCurrent() - tim_BH > 24 * Period() * 60 || (ticket_ && OrderSelect(ticket_, SELECT_BY_TICKET) && OrderCloseTime() > tim_BH &&
      TimeCurrent() - OrderCloseTime() > 5 * Period() * 60)) t_BH = false; }
//if (Day() == 5 && Month() == 5 && Hour() == 7) f_End_EA(0);

***** TST2.TXT
Digits()) + " - " + TimeToStr(CP_tim, TIME_DATE|TIME_MINUTES) + " ***"); } }
            t_BH = (t_BH? t_BH: (t_BH2=(OrderProfit() < -1.0 * fabs(OrderStopLoss() - OrderOpenPrice())/TS*TV * 0.0025 && f_wBa
rs(OrderOpenTime(), TimeCurrent()) > 24 * 60/Period()))); } }
      else  t_BH = false; }
//if (Day() == 5 && Month() == 5 && Hour() == 7) f_End_EA();

*****

***** tst1.txt
         t_Rsi515 = m3_RSI(0, iBarShift(NULL, 0, CP_tim), 2) > 31 && m3_RSI(0, iBarShift(NULL, 0, CP_tim), 2) < 69;
         for (obj = 0; obj < ObjectsTotal(); obj ++) { name = ObjectName(obj);               t_P60b = ! t_BH && (t_BH2 || t_P60);
            if ((StringFind(name, "liquid_") > 0 || StringFind(name, "BoxLine") > 0) && ObjectType(name) == OBJ_TREND/* && (! t
***** TST2.TXT
         t_Rsi515 = m3_RSI(0, iBarShift(NULL, 0, CP_tim), 2) > 31 && m3_RSI(0, iBarShift(NULL, 0, CP_tim), 2) < 69;
         for (obj = 0; obj < ObjectsTotal(); obj ++) { name = ObjectName(obj);            t_P60b = t_BH2 || t_P60;
            if ((StringFind(name, "liquid_") > 0 || StringFind(name, "BoxLine") > 0) && ObjectType(name) == OBJ_TREND/* && (! t
*****

***** tst1.txt

double t_res=0.0;       int _k=-1;
void Order_Send(datetime CP_tim,bool Sel2) { double SL, TP, SpTr, min2=500000.0;       int min=5000000;        string x_obj, x_
***** TST2.TXT

double t_res=0.0;       int _k=-1, exp_up=0, exp_dn=0;
void Order_Send(datetime CP_tim,bool Sel2) { double SL, TP, SpTr, min2=500000.0;       int min=5000000;        string x_obj, x_
*****

***** tst1.txt
               CP_tims[4] = Time[0]; }       else  tim_ex2 = Time[0];         t_box = false;       t_Send = false; } }
      if (Period() >= 240 || dtmp > 4.5) return; }          if (t_CPClose) t_CPClose = false;

***** TST2.TXT
               CP_tims[4] = Time[0]; }       else  tim_ex2 = Time[0];         t_box = false;       t_Send = false; } }
      if (Period() >= 240 || dtmp > 4.5) return;
      else { int k, k1, k2, k3, k4, k5, k6;     k1 = exp_up? exp_up - 1: 2;      k2 = exp_up == 2? 0: exp_up + 1;       k3 = exp_up;
         k4 = exp_dn? exp_dn - 1: 2;         k5 = exp_dn == 2? 0: exp_dn + 1;          k6 = exp_dn;
         if ((Exp_Ind2[k1][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k1][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind2[k1][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind2[k1][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k1][1]) + 5)) / 5.0)) ||
         (Exp_Ind2[k2][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k2][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind2[k2][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind2[k2][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k2][1]) + 5)) / 5.0)) ||
         (Exp_Ind2[k3][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k3][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind2[k3][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind2[k3][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind2[k3][1]) + 5)) / 5.0)) ||
         (Exp_Ind3[k4][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k4][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind3[k4][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind3[k4][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k4][1]) + 5)) / 5.0)) ||
         (Exp_Ind3[k5][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k5][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind3[k5][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind3[k5][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k5][1]) + 5)) / 5.0)) ||
         (Exp_Ind3[k6][0] > 4.5 && fabs((Bid + Ask) / 2.0 - (Sel2? iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k6][1]) + 5, 0)):
         iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH, iBarShift(NULL, 0, Exp_Ind3[k6][1]) + 5, 0)))) < (iHigh(NULL, 0, iHighest(NULL, 0, MODE_HIGH,
         iBarShift(NULL, 0, Exp_Ind3[k6][1]) + 5)) - iLow(NULL, 0, iLowest(NULL, 0, MODE_LOW, iBarShift(NULL, 0, Exp_Ind3[k6][1]) + 5)) / 5.0))) {
Alert("*** Exp_Ind (2)" + (Exp_Ind2[k1][0] > 4.5? " -k1 " +k1+" - "+ DoubleToStr(Exp_Ind[k1][5]+Exp_Ind[k1][8], 3) +" - "+ DoubleToStr(Exp_Ind[k1][6]+Exp_Ind[k1][9], 3) + " - " +
   DoubleToStr(Exp_Ind2[k1][0], 2) + " - " + ((k=Exp_Ind2[k1][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind2[k1][1], TIME_DATE|TIME_MINUTES):
   Exp_Ind2[k2][0] > 4.5? " -k2 " + k2 + " - " + DoubleToStr(Exp_Ind[k2][5]+Exp_Ind[k2][8], 3) + " - " + DoubleToStr(Exp_Ind[k2][6]+Exp_Ind[k2][9], 3) + " - " +
   DoubleToStr(Exp_Ind2[k2][0], 2) + " - " + ((k=Exp_Ind2[k2][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind2[k2][1], TIME_DATE|TIME_MINUTES):
   Exp_Ind2[k3][0] > 4.5? " -k3 " + k3 + " - " + DoubleToStr(Exp_Ind[k3][5]+Exp_Ind[k3][8], 3) + " - " + DoubleToStr(Exp_Ind[k3][6]+Exp_Ind[k3][9], 3) + " - " +
   DoubleToStr(Exp_Ind2[k3][0], 2) + " - " + ((k=Exp_Ind2[k3][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind2[k3][1], TIME_DATE|TIME_MINUTES): " -up : vide") +
   (Exp_Ind3[k4][0] > 4.5? " -k4 " + k4 + " - " + DoubleToStr(Exp_Ind[k4][5]+Exp_Ind[k4][8], 3) + " - " + DoubleToStr(Exp_Ind[k4][6]+Exp_Ind[k4][9], 3) + " - " +
   DoubleToStr(Exp_Ind3[k4][0], 2) + " - " + ((k=Exp_Ind3[k4][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind3[k4][1], TIME_DATE|TIME_MINUTES):
   Exp_Ind3[k5][0] > 4.5? " -k5 " + k5 + " - " + DoubleToStr(Exp_Ind[k5][5]+Exp_Ind[k5][8], 3) + " - " + DoubleToStr(Exp_Ind[k5][6]+Exp_Ind[k5][9], 3) + " - " +
   DoubleToStr(Exp_Ind3[k5][0], 2) + " - " + ((k=Exp_Ind3[k5][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind3[k5][1], TIME_DATE|TIME_MINUTES):
   Exp_Ind2[k6][0] > 4.5? " -k6 " + k6 + " - " + DoubleToStr(Exp_Ind[k6][5]+Exp_Ind[k6][8], 3) + " - " + DoubleToStr(Exp_Ind[k6][6]+Exp_Ind[k6][9], 3) + " - " +
   DoubleToStr(Exp_Ind3[k6][0], 2) + " - " + ((k=Exp_Ind3[k6][2])>0? k==2? "dn": "up": "°") + " - " + TimeToStr(Exp_Ind3[k6][1], TIME_DATE|TIME_MINUTES): " -dn : vide") + " - " +
   TimeToStr(Time[0], TIME_DATE|TIME_MINUTES) + " ***");             return; }         else
Alert("*** Exp_Ind (-) -k1 " + k1 + " - " + DoubleToStr(Exp_Ind2[k1][0], 2) + " - " + ((k=Exp_Ind2[k1][2])>0?k==2?"dn":"up":"°") + " -k2 " + k2 + " - " + DoubleToStr(Exp_Ind2[k2][0], 2) +
   " - " + ((k=Exp_Ind2[k2][2])>0? k==2? "dn": "up": "°") + " -k3 " + k3 + " - " + DoubleToStr(Exp_Ind2[k3][0], 2) + " - " + ((k=Exp_Ind2[k3][2])>0? k==2? "dn": "up": "°") +
   " -k4 " + k4 + " - " + DoubleToStr(Exp_Ind3[k4][0], 2) + " - " + ((k=Exp_Ind3[k4][2])>0? k==2? "dn": "up": "°") + " -k5 " + k5 + " - " + DoubleToStr(Exp_Ind3[k5][0], 2) + " - " +
   ((k=Exp_Ind3[k5][2])>0? k==2? "dn": "up": "°") + " -k6 " + k6 + " - " + DoubleToStr(Exp_Ind3[k6][0], 2) + " - " + ((k=Exp_Ind3[k6][2])>0? k==2? "dn": "up": "°") + " ***"); } }
   if (t_CPClose) t_CPClose = false;

*****

***** tst1.txt
   tim_exp = Time[0];         t_cpt = cpt;         t_exp = false;
   if (TimeCurrent() - t_BxClo > 2 * Period() * 60) t_BxClo = 0; }

bool Exp_Ind2() { double Exp_Sup, Exp_Inf, Exp_Med, E_Range;         bool tst=false;
   for (int obj=0; obj < ObjectsTotal() && ! tst; obj ++) { string name=ObjectName(obj);
***** TST2.TXT
   tim_exp = Time[0];         t_cpt = cpt;         t_exp = false;
   if (TimeCurrent() - t_BxClo > 2 * Period() * 60) t_BxClo = 0;

   dtmp = Exp_Ind[0][20] == Time[1]? (Exp_Ind[1][5] + Exp_Ind[1][8]) * 5.0 /      (Exp_Ind[2][5]+Exp_Ind[2][8]+Exp_Ind[3][5]+Ex
p_Ind[3][8]+Exp_Ind[4][5]+Exp_Ind[4][8]+Exp_Ind[5][5]+Exp_Ind[5][8]+Exp_Ind[6][5]+Exp_Ind[6][8]) +
      (Exp_Ind[2][5] + Exp_Ind[2][8]) * 5.0 /
      (Exp_Ind[3][5]+Exp_Ind[3][8]+Exp_Ind[4][5]+Exp_Ind[4][8]+Exp_Ind[5][5]+Exp_Ind[5][8]+Exp_Ind[6][5]+Exp_Ind[6][8]+Exp_Ind[7][5]+Exp_Ind[7][8]):
      (Exp_Ind[0][5] + Exp_Ind[0][8]) * 5.0 /
      (Exp_Ind[1][5]+Exp_Ind[1][8]+Exp_Ind[2][5]+Exp_Ind[2][8]+Exp_Ind[3][5]+Exp_Ind[3][8]+Exp_Ind[4][5]+Exp_Ind[4][8]+Exp_Ind[5][5]+Exp_Ind[5][8]) +
      (Exp_Ind[1][5] + Exp_Ind[1][8]) * 5.0 /
      (Exp_Ind[2][5]+Exp_Ind[2][8]+Exp_Ind[3][5]+Exp_Ind[3][8]+Exp_Ind[4][5]+Exp_Ind[4][8]+Exp_Ind[5][5]+Exp_Ind[5][8]+Exp_Ind[6][5]+Exp_Ind[6][8]);
   double dtmp2=Exp_Ind[0][20] == Time[1]? (Exp_Ind[1][6] + Exp_Ind[1][9]) * 5.0 /
      (Exp_Ind[2][6]+Exp_Ind[2][9]+Exp_Ind[3][6]+Exp_Ind[3][9]+Exp_Ind[4][6]+Exp_Ind[4][9]+Exp_Ind[5][6]+Exp_Ind[5][9]+Exp_Ind[6][6]+Exp_Ind[6][9]) +
      (Exp_Ind[2][6] + Exp_Ind[2][9]) * 5.0 /
      (Exp_Ind[3][6]+Exp_Ind[3][9]+Exp_Ind[4][6]+Exp_Ind[4][9]+Exp_Ind[5][6]+Exp_Ind[5][9]+Exp_Ind[6][6]+Exp_Ind[6][9]+Exp_Ind[7][6]+Exp_Ind[7][9]):
      (Exp_Ind[0][6] + Exp_Ind[0][9]) * 5.0 /
      (Exp_Ind[1][6]+Exp_Ind[1][9]+Exp_Ind[2][6]+Exp_Ind[2][9]+Exp_Ind[3][6]+Exp_Ind[3][9]+Exp_Ind[4][6]+Exp_Ind[4][9]+Exp_Ind[5][6]+Exp_Ind[5][9]) +
      (Exp_Ind[1][6] + Exp_Ind[1][9]) * 5.0 /
      (Exp_Ind[2][6]+Exp_Ind[2][9]+Exp_Ind[3][6]+Exp_Ind[3][9]+Exp_Ind[4][6]+Exp_Ind[4][9]+Exp_Ind[5][6]+Exp_Ind[5][9]+Exp_Ind[6][6]+Exp_Ind[6][9]);
   if (/*(dtmp > 4.5 || dtmp2 > 4.5 ) &&*/
   Exp_Ind[0][20] != Exp_Ind2[0][1] && Exp_Ind[0][20] != Exp_Ind2[1][1] && Exp_Ind[0][20] != Exp_Ind2[2][1] &&
   Exp_Ind[1][20] != Exp_Ind2[0][1] && Exp_Ind[1][20] != Exp_Ind2[1][1] && Exp_Ind[1][20] != Exp_Ind2[2][1] &&
   Exp_Ind[0][20] != Exp_Ind3[0][1] && Exp_Ind[0][20] != Exp_Ind3[1][1] && Exp_Ind[0][20] != Exp_Ind3[2][1] &&
   Exp_Ind[1][20] != Exp_Ind3[0][1] && Exp_Ind[1][20] != Exp_Ind3[1][1] && Exp_Ind[1][20] != Exp_Ind3[2][1]) {
Alert("*** Exp_Ind (3) - " + DoubleToStr(Exp_Ind[0][5]+Exp_Ind[0][8], 3) + " - " + DoubleToStr(Exp_Ind[0][6]+Exp_Ind[0][9], 3) + " - " +
   DoubleToStr(Exp_Ind[1][5]+Exp_Ind[1][8], 3) + " - " + DoubleToStr(Exp_Ind[1][6]+Exp_Ind[1][9], 3) + " -up " + DoubleToStr(dtmp, 2) + " - " + exp_up + " -dn " +
   DoubleToStr(dtmp2, 2) + " - " + exp_dn + " - " + TimeToStr(Exp_Ind[0][20], TIME_DATE|TIME_MINUTES) + " - " + TimeToStr(Time[0], TIME_DATE|TIME_MINUTES) + " ***");
      if (dtmp > 4.5) { Exp_Ind2[exp_up][0] = dtmp;         Exp_Ind2[exp_up][1] = (Exp_Ind[0][20] == Time[1]? Exp_Ind[1][20]: Exp_Ind[0][20]);
         Exp_Ind2[exp_up][2] = Sell + 1; }                  if (dtmp2 > 4.5) { Exp_Ind3[exp_dn][0] = dtmp2;
         Exp_Ind3[exp_dn][1] = (Exp_Ind[0][20] == Time[1]? Exp_Ind[1][20]: Exp_Ind[0][20]);        Exp_Ind3[exp_dn][2] = Sell + 1; }
         if (exp_up < 2) exp_up ++;       else  exp_up = 0;          if (exp_dn < 2) exp_dn ++;        else  exp_dn = 0; } }

bool Exp_Inds2() { double Exp_Sup, Exp_Inf, Exp_Med, E_Range;         bool tst=false;
   for (int obj=0; obj < ObjectsTotal() && ! tst; obj ++) { string name=ObjectName(obj);
*****

