Candle Scale Comparison

1. Input Parameters:
- LookbackPeriod: Allows you to set how many bars to look back for calculating averages (default: 20)
- showLabels: Toggle to show/hide dominance labels on the chart
2. Calculations:
- Calculates the scale of bullish candles (close - open)
Calculates the scale of bearish candles (open - close)
- Computes moving averages for both scales using the specified lookback period
- Determines which type of candles are dominating based on the averages
3. Visual Elements:
- Plots two lines showing the average scales:
- Green line for bullish candle scales
- Red line for bearish candle scales
- Adds a background color that changes based on dominance:
- Light green when bullish candles dominate
- Light red when bearish candles dominate
- Shows labels above the chart indicating current dominance
- Displays a table in the top-right corner showing:
- The current scale ratio (bullish/bearish)
- The current dominance status
4. Features:
- The indicator is plotted in a separate pane below the main chart
- Uses color coding for easy visual interpretation
- Provides both visual and numerical representation of the dominance
- Updates in real-time as new candles form
1. Input Parameters:
- LookbackPeriod: Allows you to set how many bars to look back for calculating averages (default: 20)
- showLabels: Toggle to show/hide dominance labels on the chart
2. Calculations:
- Calculates the scale of bullish candles (close - open)
Calculates the scale of bearish candles (open - close)
- Computes moving averages for both scales using the specified lookback period
- Determines which type of candles are dominating based on the averages
3. Visual Elements:
- Plots two lines showing the average scales:
- Green line for bullish candle scales
- Red line for bearish candle scales
- Adds a background color that changes based on dominance:
- Light green when bullish candles dominate
- Light red when bearish candles dominate
- Shows labels above the chart indicating current dominance
- Displays a table in the top-right corner showing:
- The current scale ratio (bullish/bearish)
- The current dominance status
4. Features:
- The indicator is plotted in a separate pane below the main chart
- Uses color coding for easy visual interpretation
- Provides both visual and numerical representation of the dominance
- Updates in real-time as new candles form
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Per un accesso rapido a un grafico, aggiungi questo script ai tuoi preferiti: per saperne di più clicca qui.
Declinazione di responsabilità
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Per un accesso rapido a un grafico, aggiungi questo script ai tuoi preferiti: per saperne di più clicca qui.