Using Supertrend Indicator
-
How can I integrate the Supertrend indicator?
I want to buy when the current candle is above the Supertrend.
Of course with other conditions, but in any case with the one mentioned above.
But I don't get a signal.
-
-
Supetrend is superlame. Simply don't use it. It repaints up to the last three candles.
-
I need the Supertrend to point the way. I.e. if the super trend is long, I only go long with my other indicators.
So I never act against the Supertrend indicator.
Therefore I need a signal if the Supertrend indicator is long or short. -
Is it possible to enter and calculate the formula of the Supertrend indicator?
But I have no idea how to calculate it.
-
So, you think that the indicator doesn't work. You tested it with Trace block?
-
Yes. I have no signal.

-
Sorry, it´s the Donchian Channel, but I have the same problem with the supertrend indicator. No Signal.
-
There is a value of 0, this is what the indicator returns. I tried this one, because I don't have your version - https://www.mql5.com/en/code/11162 - and it works. Why yours is giving you only 0... I don't know, depends how it is written, maybe this is intentional. But try with different Candle ID
-
Hello, thanks for your help.
I just don't get a signal with the custom indicator.I don't get a signal for buffer 0-2.
Where is the error ?

-
The value of 0 is the value that is returned by the indicator, I don't think that there is an error. Those indicators who return 0 are actually rare, normally the returned value (where the indicator doesn't show anything) is EMPTY_VALUE, which is some big integer. In other words, I see the value of as very intentional, the developer selected that value to be returned. If there was an error, I don't think that you would see 0.
Try with Candle ID bigger than 0.
-
Thanks for your help.
I have already played with different values.
I just don't get a signal. -
Do you see any lines of this indicator. On your screenshot I don't see any, and I think that this indicator should place some lines above and below the candles. If you see those lines, are they indicator lines (cannot be selected) or are they trend lines (objects)?
-
Hello,
these are indicator lines.
My idea is actually quite simple. I want to check if the current candle is above the yellow line (long) or below the purple line (short).
Depending on this, I want to go either long or short.
Other indicators are also used, of course. But that would be my main reason.
I hope this is understandable.

-
Hello fxDreema
Would it be possible to create an example ?
You can take any super-trend indicator.
Condition:
If the current candle is above the (yellow) super trend indicator, then long.
And vice versa. (pink line)It must be possible to query the value somehow.
Thank you for your help in advance
-
Depends on the buffers. https://fxdreema.com/tutorial/builder/indicators
Is this indicator available on the internet? -
Here ist one version with 2 buffers.
-
This indicator works fine. If one of the line is not visible, the value in the buffer is EMPTY_VALUE, which is expected. Note that if one of the two sides in "Condition" equals to EMPTY_VALUE, then the block doesn't pass.
So I used "Indicator appear" to detect line changes, it works. Well, if I use candles 0 and 1 I detected false signals... it looks that the indicator repaints a little bit. So I used candle 2:

To do the same with "Condition" block is a little bit tricky, but I did it like that:

Normally you should not use == to compare prices, but in this particular case I was able to use it. -
It doesn't work for me. Maybe I'm doing something wrong. Anyway, thank you for your help.
-
But why it doesn't work, you have error messages?
