Page 1 of 1

Specific signal

Posted: Fri Dec 08, 2023 3:01 pm
by Kpu123
Suppose I want to creat a signal only when macd indicator signal line crosses above macd line , genrate signal Buy , and no further signal after that until signal line again cross macd line how to create it ??

Re: Specific signal

Posted: Fri Dec 08, 2023 3:56 pm
by NakedMarkets
Hello,

You can use this post to design your condition, but for you it will be with the Macd indicator.
You can do the following for defining a condition when the signal line crosses above the macd line :
[Indicator Value MACD (position 0) "Signal Line"] > [Indicator Value MACD (position 0) "Macd line"] AND [Indicator Value MACD (position 1) "Signal Line"] < [Indicator Value MACD (position 1) "Macd line"]

With this condition, you check that the current value of Signal Line is above Macd Line, and you check that the previous value of Signal Line is below Macd Line. This will trigger the condition only during crossup.
You can use the Pause Rule to see that the condition works as intended.

Re: Specific signal

Posted: Fri Dec 08, 2023 4:06 pm
by Kpu123
Thanks dude