Negoziare gli spread sulle valute. Spreader 2 - pagina 14

 
Reshetov >>:


...Если поставить малый размер входному параметру profit, то депо будет слито очень быстро.



Potete dirmi come determinare la dimensione ottimale del parametro di profitto?

Forse a seconda della dimensione del deposito? Ma come esattamente?

 
A proposito, in meno di 24 ore sulla demo +10% del deposito.
 

c'è un errore nel codice.

Dobbiamo correggerne un pezzo:

   double secondlots = 0;

   for (int i = 0; i < total; i++) {
      OrderSelect( i, SELECT_BY_POS, MODE_TRADES);
      if (OrderSymbol() == Symbol()) {
         currentticket = OrderTicket();
         currentprofit = currentprofit + OrderProfit();
         currenttype = OrderType();
      }
      if (OrderSymbol() == seconds_instrument) {
         secondticket = OrderTicket();
         secondtype = OrderType();
         currentprofit = currentprofit + OrderProfit();
         secondlots = OrderLots();
      }
   }


   if (( secondticket < 0) && ( currentticket >= 0)) {
      Comment("Try close positon for " + Symbol());
      if ( currenttype == OP_BUY) {
         if (OrderClose( currentticket, lots, Bid, 2, Blue)) {
            openbarspriceonly = true;
         }
         return(0);
      } else {
         if (OrderClose( currentticket, lots, Ask, 2, Red)) {
            openbarspriceonly = true;
         }
         return(0);
      }
   }

a

   double currentlots = 0;
   double secondlots = 0;

   for (int i = 0; i < total; i++) {
      OrderSelect( i, SELECT_BY_POS, MODE_TRADES);
      if (OrderSymbol() == Symbol()) {
         currentticket = OrderTicket();
         currentprofit = currentprofit + OrderProfit();
         currenttype = OrderType();
         currentlots = OrderLots();
      }
      if (OrderSymbol() == seconds_instrument) {
         secondticket = OrderTicket();
         secondtype = OrderType();
         currentprofit = currentprofit + OrderProfit();
         secondlots = OrderLots();
      }
   }


   if (( secondticket < 0) && ( currentticket >= 0)) {
      Comment("Try close positon for " + Symbol());
      if ( currenttype == OP_BUY) {
         if (OrderClose( currentticket, currentlots, Bid, 2, Blue)) {
            openbarspriceonly = true;
         }
         return(0);
      } else {
         if (OrderClose( currentticket, currentlots, Ask, 2, Red)) {
            openbarspriceonly = true;
         }
         return(0);
      }
   }
 
vis_inet >>:
Кстати, меньше чем за сутки на демо +10% от депо.

Elenco dei mestieri in studio!

Ho avuto -20% di Depo per 2 giorni, sto testando la versione 3 oggi, finora in meno.

 
David177 >>:

Список сделок в студию!

У меня за 2 суток -20%депо, сегодня тестирую 3-ю версию, пока в общем минуса.

Qui, il saldo era di 1054 circa prima dell'inizio dei test:

Impostazioni: lotto 0,1, profitto 25.

 

Yuri, per favore fai la seconda versione per aprire i lotti specificati nelle variabili per entrambe le coppie - uguali. Grazie.

 
e che... ahem... E aggiungere il magik alla versione 3.
 
Il terzo sta davvero perdendo la testa.
 
dimasik >>:

Юрий, сделайте пожалуйста во второй версии чтобы открывал размеры лота, заданные в переменных для обеих пар - равнозначные. Спасибо.


O che la dimensione del lotto per la seconda coppia può essere specificata nelle impostazioni.
Motivazione: