(JS) Ballista

Alright so this is a script I made by combining two existing ones and making a really cool discovery that has proven very useful.

You'll notice that there are two separate oscillators that are laid on top of each other. The background oscillator is my "Tip-and-Dip" oscillator which you can see here (will refer to this as TnD from here), and the foreground oscillator from the Squeeze, which can be viewed here.

Initially I just wanted to see how they interacted with one another and compare them, but this led to some pretty interesting observations.

First let me go through the options real quick to get that out of the way, though it is mostly self-explanatory.

Lookback Period defines the amount of bars used for the TnD oscillator.
Smoothing Value smooths out the TnD output.
Standard Deviations is used to calculate the TnD formula.
Color Scheme is preset BG colors.
Using Dark Mode changes colors based on dark mode or not.
Squeeze Momentum On turns the Squeeze in the foreground off and on.
Arrows Off turns the arrows on the indicator off and on.

Now to explain the indicator a bit more. I have the default lookback period as 40 due to the Squeeze being 20, which makes the TnD oscillator the "slow" output with the Squeeze being the "fast" output.

Some initial observations were that when both the Squeeze and the TnD are moving in the direction, when the Squeeze is higher (uptrend) or lower (downtrend) it seems to indicate strength in the move. As the move loses steam you'll notice the Squeeze diverge from the TnD .

However, the most useful thing I discovered about the interaction between these two indicators is where the name for it came from. So if you aren't familiar with what a Ballista is, per Wikipedia, "The ballista... sometimes called bolt thrower, was an ancient missile weapon that launched either bolts or stones at a distant target." There are instances where the Squeeze seems to get ahead of itself and gets too far away from the TnD (which is the long term trend between the two). The key thing to look for is an "inverted squeeze" - this is when the squeeze oscillator ends up flipping against the TnD . When this occurs there is an extremely high probability that you'll see price shoot back the opposite way of the Squeeze.

I've been using this setup myself for about a year now and have been very satisfied with the results thusfar. I circled some examples on the SPX daily chart here to show you what I mean with the inverted Squeeze shooting back.
Mã nguồn mở

Với tinh thần của TradingView, tác giả đã xuất bản tập lệnh theo mã nguồn mở, vì thế trader có thể dễ dàng hiểu và tùy chỉnh được. Bạn có thể sử dụng miễn phí, hoặc tùy chỉnh lại mã đã được cấp phép bởi Quy tắc Chung. Bạn có thể sử dụng nó trên biểu đồ.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?

Bình luận

what timeframe do you recommend ?
+3 Phản hồi
gmeneguzzo gmeneguzzo
@gmeneguzzo, which are best buy and sell conditions using your alerts Downtrend Top and Uptrend Bottom are ok ?
+2 Phản hồi
sg_one gmeneguzzo
@gmeneguzzo, This is so perfect for binary trading, use 1 min timeframe and set 3 min exit time (OLYMPTRADE).
You wont suffer more than 4 consecutive losses in a row
+1 Phản hồi
@sg_one, what do you use to enter , Uptrend Bottom alert ?
Phản hồi
this seems so good wtf? cheatcode need to backtest, thanks for the opportunity sir
+1 Phản hồi
J-Streak raitocrypto
@raitocrypto, works exceptionally well in volatility too - take a look at it on a 30 minute chart of SPX during the COVID drop, lots of good examples of the inverted Squeeze shooting back there as well.
Phản hồi
raitocrypto J-Streak
@J-Streak, I just did. It's pretty insane! It gives a lot of signal but i can smooth it out pretty easily from what I see for now. What is your experience in micro timeframe(1-3-5min) ? I'm a scalper.
Phản hồi
J-Streak raitocrypto
@raitocrypto, I day trade futures - it works the same, smaller time frame just means smaller move is all
Phản hồi
raitocrypto J-Streak
@J-Streak, Cool thank you, well it depend, I have a momentum delta osci that is clearly better in ltf, that is why.
Phản hồi
J-Streak raitocrypto
@raitocrypto, here it is on a 5 minute ES chart, all 4 instances saw a move the opposite way.
Phản hồi