OPEN-SOURCE SCRIPT
Coefficient of Variance Bars

The script calculates the Coefficient of Variance (CV), which is the standard deviation (a measure of volatility) divided by the average price over a set period. In simple terms, it tells you how volatile the market is in relation to its current price level.
• Highlighting Volatility Increase: By default, the script colors the bars when this relative volatility makes a new high. This suggests that the market is "waking up" and that a significant price move could be starting.
• Highlighting Low Volatility (Inverse Mode): When you uncheck the box in the settings, it highlights periods where volatility is not making a new high. This is useful for spotting quiet, consolidating markets.
________________________________________
How to Use It in Trading
This indicator is a complementary tool and should be used with other forms of analysis, like price action or trend indicators.
1. Spotting Potential Breakouts
The most common use is to anticipate breakouts. When the price is moving in a tight range (consolidation) and you suddenly see a highlighted bar, it signals a surge in volatility. This is often the catalyst that pushes the price out of the range.
• Strategy: Look for a period of price consolidation. When a bar is colored, indicating a volatility spike, look for a confirmation of a breakout (e.g., a candle closing above resistance or below support) and consider entering a trade in that direction.
2. Identifying Ranging Markets
By switching to the inverse mode, you can easily see when the market is quiet and range-bound.
• Strategy: When the bars are consistently highlighted in inverse mode, it confirms a ranging market. This is the ideal environment for strategies that capitalize on sideways movement, such as using oscillators (like RSI or Stochastics) to trade between support and resistance levels.
3. Gauging Trend Strength and Exhaustion
In a strong, ongoing trend, you'll likely see intermittent volatility spikes confirming the momentum. However, a sudden, massive spike in volatility after a very long trend might signal a "climax," potentially indicating the trend is exhausted and a reversal could be near.
• Highlighting Volatility Increase: By default, the script colors the bars when this relative volatility makes a new high. This suggests that the market is "waking up" and that a significant price move could be starting.
• Highlighting Low Volatility (Inverse Mode): When you uncheck the box in the settings, it highlights periods where volatility is not making a new high. This is useful for spotting quiet, consolidating markets.
________________________________________
How to Use It in Trading
This indicator is a complementary tool and should be used with other forms of analysis, like price action or trend indicators.
1. Spotting Potential Breakouts
The most common use is to anticipate breakouts. When the price is moving in a tight range (consolidation) and you suddenly see a highlighted bar, it signals a surge in volatility. This is often the catalyst that pushes the price out of the range.
• Strategy: Look for a period of price consolidation. When a bar is colored, indicating a volatility spike, look for a confirmation of a breakout (e.g., a candle closing above resistance or below support) and consider entering a trade in that direction.
2. Identifying Ranging Markets
By switching to the inverse mode, you can easily see when the market is quiet and range-bound.
• Strategy: When the bars are consistently highlighted in inverse mode, it confirms a ranging market. This is the ideal environment for strategies that capitalize on sideways movement, such as using oscillators (like RSI or Stochastics) to trade between support and resistance levels.
3. Gauging Trend Strength and Exhaustion
In a strong, ongoing trend, you'll likely see intermittent volatility spikes confirming the momentum. However, a sudden, massive spike in volatility after a very long trend might signal a "climax," potentially indicating the trend is exhausted and a reversal could be near.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。