SushilKothawade

Catch the Big Fish

2670 просмотров
282
Volume based script to catch a big move. Works best on 5 min timeframe.
The default sma duration for volume is set to 150 = number of candles in 5 mins timeframe for 2 days.
Heavy volume is defined as = more than 9 times of sma .
Both parameters are configurable.
Trading strategy: Long buy at high / Short sell at low of the candle where the script gives the signal.
Important note regarding SL - for Long / Short positions respectively, the SL should be placed at low / high of previous candle, and NOT of the same candle.
Удалить из избранных скриптов Добавить в избранные скрипты

Комментарии

I have added strategy coding and it now works, however, the prediction accuracy is not desireble. Let me know if you see differently. Thanks.

longCondition = longBrkOut
if (longCondition and year==2020)
strategy.entry("Strategy Long", strategy.long,qty=100)
shortCondition = shortBrkOut
if (shortCondition and year==2020)
strategy.entry("Strategy Short", strategy.short, qty=100)
+1 Ответить
// © SushilKothawade

//@version=4
strategy("Catch the Big Fish", overlay=true)
useStrat = input(true, "Use Strategy Setup")
yr = input(2019, "Starting backtest year", minval=2000)
mn = input(8, "Starting backtest month", minval=1, maxval=12)
dy = input(1, "Starting backtest day", minval=1, maxval=31)

multiplier = input(9, title="Volume multiplier")
duration = input(150, title="Volume SMA duration")
heavyVolume = volume > (sma(volume, duration) * multiplier)

calcLongBrkOut()=>

x = 0.0

if (heavyVolume and close < open)
x := high
else if (x > 0)
x := x

x

calcShortBrkOut()=>

x = 0.0

if (heavyVolume and close > open)
x := low
else if (x > 0)
x := x

x

longBrkOutVal = calcLongBrkOut()
shortBrkOutVal = calcShortBrkOut()

buyLbl = "Go long"
// sellLbl = "Sell the long"
slLong = "SL - Low of prev candle"

shortLbl = "Go short"
// coverLbl = "Cover the short"
slShort = "SL = High of prev candle"

longBrkOut = longBrkOutVal > 0 and close >= longBrkOutVal and low <= longBrkOutVal and close >= close and close >= open and close >= open
shortBrkOut = shortBrkOutVal > 0 and close <= shortBrkOutVal and high >= shortBrkOutVal and close <= close and close <= open and close <= open

plotshape( longBrkOut ? 1 : na, style = shape.labeldown , color = color.teal , location = location.abovebar, size = size.small, text = buyLbl, textcolor=color.white)
plotshape( longBrkOut ? 1 : na , style = shape.labelup , color = color.orange , location = location.belowbar , size = size.tiny, text = slLong, textcolor=color.white)
// plotshape( shortBrkOutVal != shortBrkOutVal and shortBrkOutVal > 0 ? 1 : na , style = shape.labeldown , color = color.blue , location = location.abovebar , size = size.small, text = sellLbl, textcolor=color.white)

plotshape( shortBrkOut ? 1 : na, style = shape.labelup , color = color.red , location = location.belowbar, size = size.small, text = shortLbl, textcolor=color.white)
plotshape( shortBrkOut ? 1 : na , style = shape.labeldown , color = color.maroon , location = location.abovebar , size = size.tiny, text = slShort, textcolor=color.white)
// plotshape( longBrkOutVal != longBrkOutVal and longBrkOutVal > 0 ? 1 : na , style = shape.labelup , color = color.purple , location = location.belowbar , size = size.small, text = coverLbl, textcolor=color.white)

//*** Strategy
if useStrat and year >= yr and month >= mn and dayofmonth >= dy
strategy.entry("BUY", true, 1, when=longBrkOut)
strategy.entry("SELL", false, 1, when=shortBrkOut)
Ответить
waiting for your new script "Following the Pullback"
Ответить
Looks like a nice indicator but couldn't get to work. Tried it with different volume indicators with no luck. 🙁
Ответить
Hi Sushil Ji, It would be good if you can make strategy tester too :)
Ответить
shahrachit shahrachit
@SushilKothawade : Can you please also explain the logic how did you create it / logic behind trade.
Ответить
@shahrachit, heavy volume generally indicates institutional / promoter buying / selling.. which basically means, something is about to happen in the stock, which retailers are not aware.
price movement below a bullish candle / above a bearish candle mostly ensures a trend reversal.
But, nothing is perfect on charts, so stop loss is more important.
+1 Ответить
Why I m not seeing anything here or it works only in live market. plz reply. thank you
Ответить
miteysh subhdash1984
@subhdash1984, this script requires scrip with volume .... Index won't show volume rather futures will.
+1 Ответить
Домой Скринер акций Скринер форекс Скринер криптовалют Экономический календарь О проекте Особенности Цены Приведи друга Правила поведения Справочный центр Решения для сайтов и брокеров Виджеты Графики TradingView для сайтов Легкая версия графиков Блог и новости Твиттер
Профиль Настройка профиля Счёт и оплата Ваши друзья Монеты Мои запросы в поддержку Справочный центр Опубликовано идей Подписчики Подписки Личные сообщения Чат Выйти