Sharpe Ratio BTC vs GoldIt calculates the Sharpe Ratio for Bitcoin (BTCUSDT) and Gold (XAUUSD).
Uses log returns to compute risk-adjusted returns.
Takes a 30-day lookback period by default.
Risk-free rate is set at 3% annualized, converted to daily.
Plots both Sharpe Ratios on the same chart: Bitcoin (Blue line), Gold (Red line)
Penunjuk dan strategi
Correlation Table Small MonitorCorrelation table for small Monitor (separato in 2 Tabelle)
Uno strumento avanzato per l'analisi delle correlazioni in tempo reale
Funzionalità Principali:
1. **Monitoraggio Multi-Asset**
Analizza **32 coppie/strumenti** simultaneamente, includendo:
- Forex maggiori e incroci (EURUSD, GBPJPY, ecc.)
- Materie prime (Oro, Argento, Petrolio WTI e Brent)
- Coppie esotiche (NZDCAD, AUDNZD, ecc.)
2.Correlazione Dinamica
Calcola la correlazione rispetto allo strumento principale visualizzato sul grafico:
- Periodo regolabile (default: 50 candele)
- Formula matematica basata sulla covarianza
- Risultati in percentuale (-100% a +100%)
3. Visualizzazione Intuitiva
- Tabella verticale con codifica colore:
- **Verde**: Correlazione positiva (↑↑)
- **Rosso**: Correlazione negativa (↑↓)
- **Bianco**: Neutralità (-0.1 < correlazione < +0.1)
- Intensità del colore proporzionale alla forza della correlazione
4. Aggiornamento in Tempo Reale
- Dati sincronizzati con il timeframe selezionato
- Posizionamento non invasivo (angolo inferiore destro)
Componenti Tecnici:
- input Personalizzabili:
- Simboli modificabili direttamente dalle impostazioni
- Lunghezza periodo di correlazione regolabile
- Supporto per simboli personalizzati (es. CFD su materie prime)
- Logica di Calcolo:
```pinescript
correlation = covarianza / √(varianza1 * varianza2)
```
- Utilizza SMA per smoothing
- Normalizzazione statistica per risultati comparabili
Use Case Pratici:
1. Diversificazione del Portafoglio
Identifica asset non correlati per ridurre il rischio.
2. Conferma di Trend
Verifica co-movimenti con strumenti correlati (es. EURUSD e GBPUSD).
3. Hedging Strategico
Trova correlazioni inverse per operazioni di copertura (es. Oro vs USD).
4. Analisi Intermarket
Monitora relazioni tra valute e materie prime (es. CAD vs petrolio).
Personalizzazione:
- Aggiungi/rimuovi coppie modificando gli input `pair1`-`pair32`
- Modifica la soglia di neutralità (`neutral_threshold`)
- Regola l'opacità dei colori modificando `intensity`
Limitazioni:
- Dipendente dalla qualità dei dati del broker
- Le correlazioni storiche non garantiscono performance future
Ideale per: Swing trader, portafogli multi-asset, analisti macro. Offre una visione d'insieme rapida delle relazioni di mercato senza bisogno di multipli grafici aperti.
Consiglio:
In time frame inferiori a M15, si consiglia di aumentare i periodi per evitare un rumore statistico eccessivo. (Es. 80 - 100)
useGridDcaLibrary "useGridDca"
TODO: add library description here
genPlaceholderLine(array_len, line_color, line_width, line_style)
Parameters:
array_len (int)
line_color (color)
line_width (int)
line_style (string)
updateArrLine(index, arr_line, new_pos)
Parameters:
index (int)
arr_line (array)
new_pos (float)
genPlaceholderLabel(array_len, label_color, label_size, label_style, label_text_color)
Parameters:
array_len (int)
label_color (color)
label_size (string)
label_style (string)
label_text_color (color)
updateArrLabel(index, arr_label, new_pos, new_label, new_toottip, offset)
Parameters:
index (int)
arr_label (array)
new_pos (float)
new_label (string)
new_toottip (string)
offset (int)
sma 9/20 crossThis Pine Script is designed to visualize the crossover between two Simple Moving Averages (SMAs) on a chart: a fast SMA (9-period) and a slow SMA (20-period). The script will dynamically adjust the background color based on whether the fast SMA is above or below the slow SMA.
Key Components of the Script:
Inputs for SMA Lengths:
The script allows you to adjust the lengths of the two SMAs by inputting values for smaFastLength (default = 9) and smaSlowLength (default = 20). These lengths define how many periods (candles) the SMAs consider when calculating the moving averages.
SMA Calculations:
The script calculates two SMAs using the close price:
smaFast is the 9-period SMA.
smaSlow is the 20-period SMA.
These are calculated using TradingView’s built-in ta.sma function, which computes the simple moving average for the given period.
Background Color Logic:
The background color is dynamically updated based on the crossover condition:
Green background: When the fast SMA (smaFast) is above the slow SMA (smaSlow), indicating a bullish trend.
Red background: When the fast SMA is below the slow SMA, indicating a bearish trend.
The bgcolor function is used to change the background color on the chart. The transparency of the background color is set to 35% using color.new(color.green, 35) or color.new(color.red, 35).
Plotting the SMAs:
The two SMAs are plotted on the chart for visual reference:
The fast SMA is plotted in lime green (color.blue).
The slow SMA is plotted in red (color.red).
sma 9/20 crossThis Pine Script is designed to visualize the crossover between two Simple Moving Averages (SMAs) on a chart: a fast SMA (9-period) and a slow SMA (20-period). The script will dynamically adjust the background color based on whether the fast SMA is above or below the slow SMA.
Key Components of the Script:
Inputs for SMA Lengths:
The script allows you to adjust the lengths of the two SMAs by inputting values for smaFastLength (default = 9) and smaSlowLength (default = 20). These lengths define how many periods (candles) the SMAs consider when calculating the moving averages.
SMA Calculations:
The script calculates two SMAs using the close price:
smaFast is the 9-period SMA.
smaSlow is the 20-period SMA.
These are calculated using TradingView’s built-in ta.sma function, which computes the simple moving average for the given period.
Background Color Logic:
The background color is dynamically updated based on the crossover condition:
Green background: When the fast SMA (smaFast) is above the slow SMA (smaSlow), indicating a bullish trend.
Red background: When the fast SMA is below the slow SMA, indicating a bearish trend.
The bgcolor function is used to change the background color on the chart. The transparency of the background color is set to 35% using color.new(color.green, 35) or color.new(color.red, 35).
Plotting the SMAs:
The two SMAs are plotted on the chart for visual reference:
The fast SMA is plotted in lime green (color.lime).
The slow SMA is plotted in red (color.red).
Global M2 Money Supply // Days Offset =Global M2 vs BTC / Days Offset
Chart Explained
This chart illustrates the year-over-year growth in the global money supply (M2) from the top 21 central banks, compared to the price of Bitcoin. The M2 Global measure includes cash, checking and savings deposits, money market accounts, and smaller deposits under $100,000.
An increase in global liquidity indicates that major central banks are making more money available to their economies. They typically achieve this by lowering interest rates or purchasing government bonds and other securities to expand the money supply.
When comparing Bitcoin’s price to the M2 growth rates of central banks like the FED, ECB, PBoC, BoJ, and others, there is a clear correlation—Bitcoin tends to rise in tandem with the growth of the M2 supply. Historically, Bitcoin bull markets have aligned with periods of increased global liquidity.
Indicator Explained
Press settings and add a 72 day offset (or whatever works best for you)
Data for the global money supply has been sourced from the following 21 central banks:
North America: USM, CAM
Eurozone: EUM
Non-Eurozone Europe: CHM, GBM, FIPOP, RUM
Pacific: NZM
Asia: CNM, TWM, HKM, INM, JPM, PHM, SGM
Latin America: BRM, COM, MXM
Middle East: AEM, TRM
Africa: ZAM
This comprehensive data set offers insights into how global liquidity impacts the price of Bitcoin, reinforcing the historical connection between monetary expansion and Bitcoin’s bull markets.
Naveen %R (140) ScreenerNaveen %R (140) Screener
Description: The "Naveen %R (140) Screener" is a custom-built Pine Script indicator designed to identify oversold and overbought conditions in the cryptocurrency market. Tailored for traders who focus on altcoins, this indicator provides a sophisticated approach to market analysis using the Williams %R formula, adapted with a longer period of 140 to capture more extensive market cycles.
Features:
Longer Lookback Period: Utilizes a 140-period high and low to calculate the Williams %R, providing a broader view of market sentiment and potential reversals.
Oversold and Overbought Signals: Clearly marks oversold conditions when the indicator value falls below -95, and overbought conditions when it rises above -5.
Customizable Alerts: Traders can set alerts for oversold and overbought signals, enabling timely decisions based on specific trading strategies.
Visual Tools: Includes blue lines to display the Williams %R values, with red and green horizontal lines marking overbought and oversold thresholds, respectively.
Screener Compatibility: Optimized for use in TradingView’s cryptocurrency screener, allowing traders to filter and identify potential trading opportunities across multiple altcoins based on the indicator’s signals.
Use Case: Ideal for traders looking for a reliable technical tool to gauge extreme conditions in the altcoin markets. Whether you are a day trader aiming for quick turnovers or a long-term investor looking for entry and exit points, the Naveen %R (140) Screener helps you navigate the volatility with more confidence.
How to Use:
Apply the indicator to any cryptocurrency chart within TradingView.
Configure alerts to be notified when oversold or overbought conditions are met.
Use the output of this script to filter altcoins in the TradingView screener, helping you focus your analysis on coins that meet specific criteria set by the indicator.
Perfect for both new and experienced traders, the "Naveen %R (140) Screener" is a must-have tool in your trading arsenal to enhance your decision-making process and refine your trading strategies.
Naveen %R (140) Top 40 ScreenerTitle: Naveen %R (140) Top 40 Screener
Description:
The "Naveen %R (140) Top 40 Screener" is a specialized TradingView indicator designed to assess the relative strength of the top 40 cryptocurrency pairs listed on Binance, excluding stablecoins. This indicator calculates the Naveen %R, a variant of the Williams %R indicator, over a span of 140 periods to determine overbought and oversold conditions.
Features:
Comprehensive Coverage: Tracks the top 40 crypto pairs, ensuring a broad market overview.
Custom %R Calculation: Uses a modified Williams %R formula tailored to crypto volatility and trading patterns.
Overbought and Oversold Alerts: Provides real-time alerts when a currency pair enters overbought (> -5) or oversold (< -95) territories, enabling traders to make timely decisions.
Visual Labels and Lines: Utilizes labels and horizontal lines to clearly indicate current market conditions, making it easy to scan multiple assets quickly.
Adaptability: Suitable for traders of all levels who require a reliable tool to gauge market sentiment and potential reversal points.
Ideal Use Cases:
Day Trading: Monitor quick shifts in market sentiment to capture short-term gains.
Swing Trading: Identify entry and exit points for mid-term positions based on overextended price movements.
Crypto Market Analysis: Gain a macro overview of market trends and trader behavior across major cryptocurrencies.
By integrating this indicator into your trading strategy, you can enhance your decision-making process with a robust, data-driven approach to identifying potential buy and sell opportunities based on proven technical analysis principles.
EMA & VWAP Indicatorja indicator to use to see movement
This script:
Plots the 9 EMA, 21 EMA, 50 EMA, and 200 EMA with different colors.
Adds the VWAP as a purple step-line.
Uses overlay=true so it appears directly on your price chart.
Let me know if you want any modifications! 🚀
EMA and RSI StrategyUtilizing Openai I’ve created the TradingView Pine Script for the trading bot using the 50 EMA, 20 EMA, and RSI indicators. You can view and edit the code in the canvas. Let me know if you need any modifications!
Highlight Specific Weekdayshis Pine Script highlights Tuesday, Wednesday, and Thursday on your TradingView chart by changing the background color on those days. It uses the built-in dayofweek() function to check the weekday of each bar, then applies a different semi-transparent color for each targeted day.
PA Dynamic Cycle ExplorerPA Dynamic Cycle Explorer
Very powerful tool to abserve when price cycle start or end its show us if price remains to much
time on same place so its may trend change if it was bullish move and price start consolidate
so it means may accour price losing demands and getting weaker in this way bearsh side too
try to understand do your own analysis and practice demo thnx !
RSI and EMA Strategy with LabelsVERY GOOD, SCRIPT for buy or sell, mua và bán như 1 cái máy và lời lỗ liên tục để đốt tiền sau đó sẽ thấy được vấn đề và từ đó không mua bán nữa mà giải nghệ đi làm mướn
9/20/50 EMAThis indicator plots three key Exponential Moving Averages (EMAs) on your chart: the 9 EMA (blue), 20 EMA (yellow), and 50 EMA (white). These EMAs are widely used by traders to identify trends, gauge momentum, and spot potential support/resistance levels. The combination of these EMAs provides a clear visual representation of short-term, medium-term, and long-term trends, making it easier to analyze price action and make informed trading decisions.
High Probability Liquid Bar Signals high probability liquid bar and show if the red bar generates sell signal and if the green bar generates buy signal
EMA 20/25/50/150//@version=6
indicator(title="EMA 20/25/50/150", overlay=true)
shorter = ta.ema(close, 20)
short = ta.ema(close, 25)
longer = ta.ema(close, 50)
longest = ta.ema(close, 150)
plot(shorter, color = color.red)
plot(short, color = color.yellow)
plot(longer, color = color.orange)
plot(longest, color = color.blue)
Weekend Filter Candlestick [odnac]Custom Candlestick Chart with Weekend Visibility Toggle
This indicator customizes the appearance of candlesticks by using a dark gray theme for better visibility.
Additionally, it provides an option to hide weekend candles, allowing traders to focus on weekday price action.
Features:
✅ Dark gray candlestick design for a clean and minimalistic look.
✅ Weekend hiding option – Users can enable or disable weekend candles with a simple toggle.
✅ Helps traders avoid weekend noise and focus on key market movements.
How to Use:
Add the indicator to your chart.
Use the "Hide Weekend Candles" setting to toggle weekend visibility.
When enabled, weekend candles will be hidden for a cleaner chart.
When disabled, all candles, including weekends, will be displayed.
This indicator is useful for traders who prefer to analyze weekday trends without unnecessary weekend fluctuations. 🚀