Daveatt

Dividing 2 symbols

Hello Traders

This indicator is used to divide two assets between them. Why you would ask ?
For instance, in crypto trading, traders often look at the ratio Longs/Shorts or Shorts/Longs to figure out which side is leading the market and use this information as a powerful hedge for their next trade

Enjoy
Dave
Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

Want to use this script on a chart?
💰 Results/Blogs: https://bit.ly/2ULUtjo

⏩ Signals/Pricing: https://best-trading-indicator.com/pages/pricing

🐦 Twitter: https://twitter.com/bti_trading

👉 Get a $30 discount on TradingView: https://bit.ly/2UM5OA0

📺 Youtube: https://bit.ly/3bKvnZu

Kommentarer

Hello Daveatt,
How can I add RSI indicator to this dividing 2 symbols combination? The reason is that I would like to see the relative strengh indication of these 2 symbols combination.
Thanks a lot.

dle7319
+1 Svara
Daveatt dle7319
@dle7319, not sure if it will work with the option "Add indicator on ..."
This will require some pinescripting like this

//@version=4
study(title="Dividing 2 RSI", shorttitle="Dividing 2 RSI", overlay=false)

i_a = input(defval=14, type=input.integer, title="RSI 1")
i_b = input(defval=7, type=input.integer, title="RSI 2")

symbol1 = input("MSFT", type=input.symbol title="Symbol 1")
symbol2 = input("APPL", type=input.symbol title="Symbol 2")

a = rsi(close, i_a)
b = rsi(close, i_b)

as = security(symbol1, timeframe.period,  a)
bs = security(symbol2, timeframe.period, b) 

plot(as / bs, title="DIV", color=blue) 
Svara
dle7319 Daveatt
@Daveatt, thnks a lot, Daveatt. I really appriciated it.
Svara
Thanks a lot. I was looking for such a script.
+1 Svara
Thanks mate, exactly what I was looking for.
+1 Svara
Daveatt MarkBench
@MarkBench, Glad it's helping you out :)
+1 Svara
Hem Aktie-screener Forex-screener Krypto-screener Ekonomisk kalender Om Diagramfunktioner Priser Tipsa en vän Ordningsregler Hjälpcenter Webbsidor och mäklarlösningar Widgets Diagramlösningar Lightweight Charting Library Blogg och nyheter Twitter