From 6171301cf16dc38874ec53c4774ddcf3510a45c9 Mon Sep 17 00:00:00 2001 From: moshferatu Date: Fri, 27 Oct 2023 14:45:36 -0700 Subject: [PATCH] VIX / VIX3M indicator, credit to @kerberos007 --- vix_vix3m_ratio.pine | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 vix_vix3m_ratio.pine diff --git a/vix_vix3m_ratio.pine b/vix_vix3m_ratio.pine new file mode 100644 index 0000000..35614ba --- /dev/null +++ b/vix_vix3m_ratio.pine @@ -0,0 +1,14 @@ +// Credit to @kerberos007. +//@version=5 +indicator("VIX / VIX3M", overlay = false) + +vix = request.security("VIX", "D", close) +vix3m = request.security("VIX3M", "D", close) + +vix_ratio = vix / vix3m + +fastEMA = ta.ema(vix_ratio, 7) +slowEMA = ta.ema(vix_ratio, 12) + +plot(fastEMA, color = color.green) +plot(slowEMA, color = color.red) \ No newline at end of file