CRISIS

(CRISIS) GOLD/SILVER Ratio

116 2 18
Remove from Favorite Scripts Add to Favorite Scripts
study(title="GOLD/SILVER", shorttitle="GOLD/SILVER", overlay=false)

//inputs
Sec1Input = input(defval="XAUUSD", title="First security", type=symbol, confirm=true)
Sec2Input = input(defval="XAGUSD", title="Second security", type=symbol, confirm=true)

//logic
sec(s) => security(s, period, close)
ratio = (sec(Sec1Input) / sec(Sec2Input))

//plot
plot(ratio, color=red, linewidth=3)
nice work but why not copper and oil too?
Reply
How to place trades used this ratio?
What unit sizes do you use for Gold and Silver
Reply
Ideas Scripts Chart
United States
United Kingdom
India
España
France
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Forex Signal Finder Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Account and Billing Sign Out