Heikin Ashi Double EMA Strategy [Krypt]

Based on "Heikin Ashi Strategy v2" by breizh29. Adds stop loss and optional log-transform
Удалить из избранных скриптов Добавить в избранные скрипты


Does this repaint or not? Can it be used to trade safely?
+7 Ответить
It will repaint (and it does), since it uses a bigger timeframe to get data from.
+6 Ответить
@fr0zn, the atep is final after the period in that case 180 min, the step is the average of 180 min, try smaller step, like 15 at 5 min chart, the calculation is then based of just 3, 5 min candels
+4 Ответить
@fskrypt you able to add an alert condition to the code?
+2 Ответить
Love this script! Anyone know how to set up alerts with this script?
walshie124 flowcandy
@flowcandy, //@version=2
// Based on Heikin Ashi Strategy v2 by breizh29

//strategy("Heikin Ashi Strategy ", shorttitle="HA Strategy ", overlay=true)
study("Heikin Ashi Strategy ", shorttitle="HA Strategy ", overlay=true)

res = input(title="Heikin Ashi Candle Time Frame", type=resolution, defval="60")
hshift = input(1,title="Heikin Ashi Candle Time Frame Shift")
res1 = input(title="Heikin Ashi EMA Time Frame", type=resolution, defval="180")
mhshift = input(0,title="Heikin Ashi EMA Time Frame Shift")
fama = input(1,"Heikin Ashi EMA Period")
test = input(1,"Heikin Ashi EMA Shift")
sloma = input(30,"Slow EMA Period")
slomas = input(1,"Slow EMA Shift")
logtransform = input(false, "Log Transform")
stoploss = input(true, "Stop Loss")
showplots = input(true, "Show Plots")

ha_t = heikinashi(tickerid)
ha_close = security(ha_t, res, logtransform ? log(close) : close)
mha_close = security(ha_t, res1, logtransform ? log(close) : close)

fma = ema(mha_close, fama)
sma = ema(ha_close, sloma)

plot(showplots ? (logtransform ? exp(fma) : fma) : na, title="MA", color=#0094ff, linewidth=2, style=line)
plot(showplots ? (logtransform ? exp(sma) : sma) : na, title="SMA", color=#ff6a00, linewidth=2, style=line)

golong = crossover(fma, sma)
goshort = crossunder(fma, sma)

//strategy.entry("Buy", strategy.long, when=golong, stop=(stoploss ? high+syminfo.mintick : na))
//strategy.entry("Sell", strategy.short, when=goshort, stop=(stoploss ? low-syminfo.mintick : na))

plotchar(golong, char = "L", color = green)
plotchar(goshort, char = "S", color = red)

alertcondition(golong, "long", "long")
alertcondition(goshort, "short", "short")
What does log-tranform do for this script?
Why does it repaint trades???
fskrypt PanPrezesJohny
@PanPrezesJohny, Try turning off stop loss in Settings.
MrMister88 fskrypt
@fskrypt, the step is calculated every 180min, so it juses the average of the 180 mins, if you have 5 min chart, it uses 36 candels. try with smaller step should be better. 5 min chart max step of 15 min.
+7 Ответить
Домой Скринер акций Скринер форекс Скринер криптовалют Экономический календарь О проекте Особенности Цены Приведи друга Правила поведения Справочный центр Решения для сайтов и брокеров Виджеты Графики TradingView для сайтов Легкая версия графиков Блог и новости Твиттер
Профиль Настройка профиля Счёт и оплата Приведи друга Мои запросы в поддержку Справочный центр Опубликовано идей Подписчики Подписки Личные сообщения Чат Выйти