UnknownUnicorn2188849

Altcoins Index Premiums

UnknownUnicorn2188849 Uppdaterad   
Multiple index premiums for a bunch of altcoins, all put together in one indicator.

It compares the prices of the perpetual swaps for ETH, LTC, XRP, LINK, DOT and YFI to their respective spot dollar indices.
Positive values (green) means the spot index is trading at a premium, which is considered bullish.
Negative values (red) means the spot index is trading at a discount, which is considered bearish.

In the settings you can select for which altcoin you want to display the index premium.
Only select one at the time or they'll start overlapping.

For ETH the Bitmex ETH/USD perp is used and the BETH spot dollar index.
For LTC the Bitmex LTC/USD perp is used and the BLTC spot dollar index.
For XRP the Bitmex XRP/USD perp is used and the BXRP spot dollar index.
For LINK the Bitmex LINK/USD perp is used and the BLINKT spot dollar index.
For DOT the Binance DOT/USDT perp is used and the BDOTT spot dollar index.
For YFI the Binance YFI/USDT perp is used and the BYFIT spot dollar index.

It's great for low time frame scalping and higher time frame swing trading because it shows you on all time frame whether derivatives are overheated or not.

Send me a personal message for access.
Versionsinformation:
There were overlapping value labels because of inefficient code.
I fixed the code so it's more clean now.
Versionsinformation:
Increased precision.
Versionsinformation:
Two big changes.

1.
I Added 2 more coins: BNB & XTZ.
It compares the Binance USDT perps to their respective spot indices (BBNBT & BXTZT).

2.
I switched to using the ohlc4 method instead of using closing prices as it gave much smoother and generally better results.
Versionsinformation:
In the previous update I made a small mistake with the titles which is fixed now.
I also updates the tags.
Versionsinformation:
Made a bunch of improvements.

It now uses all the Binance USDT perp contracts for the derivatives instead of using Bitmex perps.
Binance is the number 1 in terms of open interest and volume anyway, so it's best to use their contracts.
The spot indices are still the same.

There's now a choice field where you select a coin, which is way more practical than how it used to be.

There's also an option to color bars/candles based on whether the premium is positive or negative.
Zero values are considered positive too.
By default bar coloring is turned off.

I also added a baseline at the zero level.
Versionsinformation:
Replaced the ETH premium with ADA because ETH gets a separate premium indicator since it's too big of a market.

And to clarify: all the perps are binance perps now that are compared to spot indices.
So, for example, the ADA USDT perp on Binance is compared to an ADA spot index.
Versionsinformation:
Sadly enough the data of one of the premiums was faulty.
It has been fixed.
Versionsinformation:
Small update to fix a bug.

There was a problem with the time because some indices started at different times which was messing with the data history.

All premiums now start at the first of November 2020.
Versionsinformation:
I changed the way the calculation works so that now it take the price of the chart you're looking at and compares it to the index selected.
This allows you to choose of which exchange you want to compare the altcoin perp versus its spot index.

So if you have the ADA index selected for example, make sure you're also looking at an ADA perpetual swap chart.

The indices I use are made by Bitmex. It's not that I particularly like Bitmex as an exchange, but the indices they make are pretty good.
But the LTC & XRP indices are based on dollar spot markets, the others are based on USDT spot markets.

I also added two more indices for EOS & DOGE.

And I added the option to choose the candle source. By default it takes the ohlc4 price, which gives the best results in my opinion.
Versionsinformation:
Changed a bunch of things.

First of all I flipped the premium, so the spot premium is now on the bottom and if there's a derivatives premium that's on the top side.
Spot premium is still colored green (because that's bullish), derivatives premium is grey. This is just the new theme I'm using, you can change this of course.

I added an option to display the percentage price difference or dollar difference.

I added two new coins: SOL & AAVE.

There's also a smoothing option now with a threshold you can change.

Have fun.
Versionsinformation:
I added one more coin: UNI

By the way, don't forget that the LTC & XRP indices are in USD and every other index is in USDT.
Usually USDT indices trade at lower prices than USD indices (albeit the difference is small).
Endast inbjudanskript.

Tillgången till detta skript är begränsat till användare som har godkänts av författaren och kräver vanligtvis betalning. Du kan lägga till det till dina favoriter men du kan bara använda det efter att ha begärt och fått författarens tillstånd. Kontakta UnknownUnicorn2188849 för mer information eller följ författarens instruktioner här under.

TradingView rekommenderar inte att du betalar för ett skript och använder det om du inte litar till 100% på författaren och förstår hur skriptet fungerar. I många fall kan du hitta ett bra alternativ med öppen källkod gratis i våra Community skripts .

Frånsägelse av ansvar

Informationen och publikationerna är inte avsedda att vara, och utgör inte heller finansiella, investerings-, handels- eller andra typer av råd eller rekommendationer som tillhandahålls eller stöds av TradingView. Läs mer i Användarvillkoren.

Författarens instruktioner

Författaren till detta skript kan inte längre ge åtkomst till det. Begär inte åtkomst.

Vill du använda det här skriptet i ett diagram?

Varning:Var god läs innan du begär åtkomst.