[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 486

 
Noterday писал(а) >>

Doesn't draw :((.

s.w. k=0 I finished it :)


Drawing, but what is it supposed to draw
Files:
 
How to take readings on the ZigZag indicator (non-reversible) with a breakout level. I am interested in iGustom function to take values 1 or -1 at the moment of indicator switching (fixing the peak). This value serves as a trading signal for the Expert Advisor.
 
Comrades, either it's a miracle, or my skis aren't running...

Why is there such a thing in the EA code:
Print (DoubleToStr (12 / 44, 8));

It says "0.00000000" (on the "Experts" tab)?
 
Bicus писал(а) >>

Comrades, either it's a miracle or my skis aren't moving...

Why is there such a thing in the EA code:
It says "0.00000000" (on the "Experts" tab)?


Try it a little differently
Print (DoubleToStr (12.0 / 44.0, 8));
 
Vinin >>:


А попробуй немного по другому

О!!! It worked.
But how strange it seems to me.
Actually the values "12" and "44" sit in variables of type "int". Am I right in assuming that they must now be declared as "double"?

 
Bicus писал(а) >>

О!!! It worked.
But how strange it seems to me.
Actually the values "12" and "44" sit in variables of type "int". Am I right in assuming that they must now be declared as "double"?


Exactly right. Or do an implicit conversion
 
Vinin >>:


Совершенно верно. Или делать неявное преобразование

Thank you very much, that's helpful.

:)

 
How would the code look like:
opening a Buy position with a 20 pips profit
30 pips up from Buy, set 5 pending orders 30 pips apart: Sell order with a 20 pips profit.
30 pips down from Buy, set 5 pending orders 30 pips apart: Buy order with a 20 pips profit.
 
Danil93 >>:
как будет выглядеть код для такого:
открытие позиций Buy с профитом 20пунктов
выше от Buy на 30пунктов выставляем 5 отложенных ордеров с растоянием друг от друга в 30пунктов: ордера на Sell с профитом в 20пунктов.
ниже от Buy на 30пунктов, выставляем 5 отложенных ордеров с растоянием друг от друга в 30пунктов: ордера на Buy с профитом в 20пунктов.

Search for the keyword 'grider'.

 
Luchiy >>:
Как снимать показатели на индикаторе ZigZag(неперересовывающем) c отстоющим уровнем пробития цены. Интересует чтобы в момент переключения индикатора (фиксации вершины) функция iGustom принимала значения 1 либо -1. Это значение служит торговым сигналом для советника.

To analyse and work with indicators such as ZigZag, it is necessary to cycle through the values of the buffer from 0 bar to the very last. While searching the values, remember the last non-empty value and compare it to those non-empty values that will be encountered during the search. The peculiarity of such indicators is that the line is connected between non-empty values of the indicator buffer, therefore in order to determine where the break has occurred, and in which direction, we should try all the last values from 0 to the very last one. However, as soon as the necessary information is found, the loop should be stopped immediately, which will reduce the time to the minimum required value. The loop can be used for any calculations and analysis, as long as it is organized correctly.

In this case it should be enough to compare only two non-empty values of the buffer, that is the first value starting from 0 bar and the second non-empty value following it.