Объяснение: longCloseCondition и shortCloseCondition: Эти условия проверяют, что цена закрытия свечи выше или ниже соответствующей скользящей средней.
longCloseCondition проверяет, что цена закрытия выше красной (EMA 12) и был сигнал на лонг. shortCloseCondition проверяет, что цена закрытия ниже синей (EMA 30) и был сигнал на шорт. returnToTrendLong и returnToTrendShort: Эти условия определяют, когда цена возвращается в тренд после ложного сигнала.
Теперь сигнал будет генерироваться, когда цена закрытия свечи находится на уровне ближайшей скользящей средней (т.е. выше для лонга и ниже для шорта), что можно воспринимать как закрытие свечи телом на уровне MA.
Protected script
This script is published as closed-source. However, you can use it freely and without any limitations – learn more here.
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.