Combined EMA Score & Moving Averages Indicatorfinal ema score calculation with moving avg Combined EMA Score & Moving Averages IndicatorCombined EMA Score & Moving Averages IndicatorCombined EMA Score & Moving Averages IndicatorCombined EMA Score & Moving Averages IndicatorCombined EMA Score & Moving Averages IndicatorCombined EMA Score & Moving Averages Indicator
Breadth Indicators
Very Steep & Crossed Lin Reg_Published Ver.1.1このスクリプトについて/Summary of this Script
このスクリプトは、LinRegが急上昇をしている銘柄をTrading Viewのスクリーニングで発見するためのものです。LinRegが急上昇する過程で、下側の線並びに50MAなど他の指標との重なりのあるポイントでエントリーすることで、低リスクエントリーを可能にすることを狙っています。チャート上で使用するものではありません。
This script is for screening stocks that have "Very steep & crossed, triangle shaped LinReg" chart.
To find out stocks that have those shaped chart as much as possible, it helps our low risk entry strategy.
このスクリプトの目的/This Script's objective, condition & specification is as following
<目的>
TradingViewのリストにある銘柄の中から、線形回帰が急上昇して、交差している銘柄をスクリーニング結果に表出すること。
<条件>
-今日以降で線形回帰が交差するチャート
<仕様>
**Trading ViewのPine script ver5**
このスクリプトの使い方How to use this script for Trading View Pine Screening
日本語
1. チャートにPine Scriptを設定する
2. チャート上では非表示にする (スクリーナー用のため)
3. Pineスクリーナー用のリストを作成する(新規が良い)
4. Pine Screenerの画面(jp.tradingview.com/pine-screener/)で、「スクリーニングするリストの指定」 → 「使用するPineスクリーナーの選択」をする
5. Pine ScreenerのScreener Signalの設定をする (0.1以上など)
6. スキャンを実行する
7. 結果が出た銘柄を入れるための、リストを作成する(新規)
8. Trading Viewのスーパーチャートで、目視検証をする(前提は日足で、急上昇で三角に交差しているLinReg銘柄を探すこと)
English
How to use this script for Trading View Pine Screening
1. Set Pine Script on the chart
2. Hide it on the chart (for the screener)
3. Create a list for the Pine Screener (a new one is better)
4. On the Pine Screener screen (/pine-screener/), select "Specify list to screen" → "Select Pine Screener to use"
5. Set the Screener Signal for Pine Screener (0.1 or higher, etc.)
6. Run the scan
7. Create a list (new) to put stocks with results
8. Visually verify on Trading View's Super Chart (the premise is to look for LinReg stocks that are rising sharply and crossing a triangle on the daily chart)
注意事項/Notes : Not prediction, assumption based on past data of Linear Regression
Pine Script doesn't have capability to predict future chart shape.
So, this script is developed provides selecting similar chart pattern of "steep triangle shaped linear regression" based on using past data.
Definition is as followings.
*These description will be translated in English soon, but not yet as of 24th Feb, 2025.
🔎 交差の定義
「線形回帰の上側の線と下側の線が交差する」という状況は、以下のように定義できます:
過去のデータから 上側の線と下側の線の距離が縮まっている(収束している)
その傾向が続くと 近い将来に交差する可能性がある
📌 交差の可能性を定義するための要素
以下の3つの要素を組み合わせて、交差の可能性をスクリーニングできます。
① 上側の線と下側の線の差(スプレッド)が縮小している
pinescript
コピーする
編集する
spread_now = linreg_upper - linreg_lower
spread_prev = linreg_upper - linreg_lower
spread_shrinking = spread_now < spread_prev
spread_now … 現在の線形回帰バンドの幅
spread_prev … 1本前のローソク足の線形回帰バンドの幅
spread_shrinking … バンド幅が縮小している(交差しそう)
② 線形回帰の上側の線の傾きが下がり、下側の線の傾きが上がっている
pinescript
コピーする
編集する
slope_upper = linreg_upper - linreg_upper
slope_lower = linreg_lower - linreg_lower
converging = slope_upper < 0 and slope_lower > 0
slope_upper … 上側の線の傾き(負なら下降)
slope_lower … 下側の線の傾き(正なら上昇)
converging … 上側の線が下がり、下側の線が上がっている(交差に向かっている)
③ 交差までの推定日数が近い
pinescript
コピーする
編集する
estimated_days_to_cross = spread_now / (abs(slope_upper) + abs(slope_lower))
soon_to_cross = estimated_days_to_cross < 5
estimated_days_to_cross … 交差するまでの推定日数(幅 ÷ 傾きの変化量)
soon_to_cross … 5日以内に交差しそうなら true
✅ 交差の可能性をスクリーニング
pinescript
コピーする
編集する
screener_condition = spread_shrinking and converging and soon_to_cross
spread_shrinking … 線形回帰バンドの幅が縮小
converging … 上側の線が下降し、下側の線が上昇
soon_to_cross … 5日以内に交差しそう
📌 TradingView の Pine Script に組み込む
これらの要素を組み合わせて、TradingView のスクリーニング用 Pine Script に落とし込むと、以下のようになります。
pinescript
コピーする
編集する
//version=5
indicator("Linear Regression Convergence Screener", overlay=false)
// === 設定 ===
length = 100 // 線形回帰の計算期間
mult = 2.0 // 標準偏差の倍率
// === 線形回帰の計算 ===
linreg_mid = ta.linreg(close, length, 0) // 中心線
std_dev = ta.stdev(close, length) // 標準偏差
linreg_upper = linreg_mid + (std_dev * mult) // 上側の線
linreg_lower = linreg_mid - (std_dev * mult) // 下側の線
// === 交差の可能性の判定 ===
// ① 上側の線と下側の線の差が縮小
spread_now = linreg_upper - linreg_lower
spread_prev = linreg_upper - linreg_lower
spread_shrinking = spread_now < spread_prev
// ② 上側の線が下がり、下側の線が上がっている
slope_upper = linreg_upper - linreg_upper
slope_lower = linreg_lower - linreg_lower
converging = slope_upper < 0 and slope_lower > 0
// ③ 交差までの推定日数が5日以内
estimated_days_to_cross = spread_now / (abs(slope_upper) + abs(slope_lower))
soon_to_cross = estimated_days_to_cross < 5
// === スクリーニング条件 ===
screener_condition = spread_shrinking and converging and soon_to_cross
// === プロット(スクリーニング結果) ===
plot(screener_condition ? 1 : na, title="Screener Signal", style=plot.style_columns, color=color.green)
✅ スクリプトの動作
交差する可能性のある銘柄をスクリーニング
過去のデータをもとに「バンドが縮小」「上側が下降」「下側が上昇」「5日以内に交差しそう」な銘柄を選定
TradingViewのスクリーナーで Screener Signal が 1 の銘柄をチェック
🔎 まとめ
📌 交差の可能性を定義するには?
バンドの幅が縮小
上側の線が下降し、下側の線が上昇
交差までの推定日数を計算
📌 スクリプトで交差の可能性をスクリーニング
spread_shrinking → 線形回帰バンドの幅が縮小
converging → 上側の線が下がり、下側の線が上がっている
soon_to_cross → 交差までの推定日数が5日以内
📌 TradingViewのスクリーナーで使う
plot() を追加 してエラー回避
Screener Signal が 1 の銘柄をスクリーニング
BTC SHADJAM Smart Volume Confirmation interactivebrokers.com has been visited by 10K+ users in the past month
Interactive Brokers clients from 200+ countries and territories invest globally. Invest globally in stocks, options, futures, currencies, bonds & funds from one
Custom OBV with SMA and SignalsKey Features:
Custom OBV: This script calculates the On-Balance Volume (OBV) based on price movement and volume.
SMA on OBV: The script adds a Simple Moving Average (SMA) on top of the OBV line. The SMA period can be customized via the input parameter.
Background Shading: The background will change color when the OBV is above or below the SMA, providing visual clues for potential bullish or bearish conditions.
Green background indicates OBV is above the SMA (bullish).
Red background indicates OBV is below the SMA (bearish).
Usage:
When OBV is above the SMA: This suggests that volume is increasing in line with the price, which is typically considered bullish.
When OBV is below the SMA: This suggests that volume is decreasing or not confirming the price increase, which can be a bearish signal.
You can adjust the SMA period according to your preferences.
InnovateX//@version=6
strategy("Candle Stop Strategy Backtest", overlay=true)
// --- EMA Variables ---
ema7_length = 7
ema25_length = 25
ema99_length = 99
ema7 = ta.ema(close, ema7_length)
ema25 = ta.ema(close, ema25_length)
ema99 = ta.ema(close, ema99_length)
// --- Support and Resistance Calculation ---
lookback_support_resistance = 50
support_level = ta.lowest(low, lookback_support_resistance)
resistance_level = ta.highest(high, lookback_support_resistance)
// --- Candle Stop Function ---
is_candle_stop(trend) =>
body = math.abs(close - open)
upper_shadow = high - math.max(open, close)
lower_shadow = math.min(open, close) - low
if trend == "up"
lower_shadow >= 1.5 * body and upper_shadow < body and close > open and math.abs(ema7 - close) < body
else if trend == "down"
upper_shadow >= 1.5 * body and lower_shadow < body and close < open and math.abs(ema7 - close) < body
else
false
// --- Trend Determination ---
trend = ema25 > ema99 ? "up" : ema25 < ema99 ? "down" : "neutral"
// --- Breakout Detection ---
var bool breakout_detected = false
if trend == "up" and close > resistance_level
breakout_detected := true
alert("شکست صعودی تشخیص داده شد! منتظر پولبک 🚀", alert.freq_once_per_bar)
else if trend == "down" and close < support_level
breakout_detected := true
alert("شکست نزولی تشخیص داده شد! منتظر پولبک 📉", alert.freq_once_per_bar)
// --- Entry and Exit Conditions ---
var float position = 0.0
var float entry_price = 0.0
var float stop_loss_price = na
var bool take_profit_long = false // Declare take_profit_long
var bool stop_loss_hit_long = false // Declare stop_loss_hit_long
var bool take_profit_short = false // Declare take_profit_short
var bool stop_loss_hit_short = false// Declare stop_loss_hit_short
risk_per_trade_percent = 2.0 // Risk percentage per trade - adjustable in strategy settings
if not breakout_detected
if position == 0 and is_candle_stop(trend)
risk_amount_usd = strategy.initial_capital * (risk_per_trade_percent / 100)
if trend == "up"
stop_loss_price := math.min(low, support_level * 0.99)
if (close - stop_loss_price) != 0
position_size_usd = risk_amount_usd / (close - stop_loss_price)
amount = position_size_usd / close
strategy.entry("Long", strategy.long, qty=amount)
position := amount
entry_price := close
else if trend == "down"
stop_loss_price := math.max(high, resistance_level * 1.01)
if (stop_loss_price - close) != 0
position_size_usd = risk_amount_usd / (stop_loss_price - close)
amount = position_size_usd / close
strategy.entry("Short", strategy.short, qty=amount)
position := amount
entry_price := close
if position > 0
profit_percent_long = (close - entry_price) / entry_price * 100
profit_percent_short = (entry_price - close) / entry_price * 100
loss_percent_long = (entry_price - close) / entry_price * 100
loss_percent_short = (close - entry_price) / entry_price * 100
risk_reward_long = loss_percent_long != 0 ? profit_percent_long / loss_percent_long : profit_percent_long
risk_reward_short = loss_percent_short != 0 ? profit_percent_short / loss_percent_short : profit_percent_short
take_profit_long := profit_percent_long >= 4 and risk_reward_long >= 2 // Assign value to take_profit_long
stop_loss_hit_long := close <= stop_loss_price // Assign value to stop_loss_hit_long
take_profit_short := profit_percent_short >= 4 and risk_reward_short >= 2 // Assign value to take_profit_short
stop_loss_hit_short := close >= stop_loss_price // Assign value to stop_loss_hit_short
if (trend == "up" and (take_profit_long or stop_loss_hit_long)) or (trend == "down" and (take_profit_short or stop_loss_hit_short))
if trend == "up"
strategy.close("Long")
else
strategy.close("Short")
position := 0
entry_price := 0.0
breakout_detected := false
// --- Plotting EMAs and Support/Resistance Levels ---
plot(ema7, color=color.blue, title="EMA7")
plot(ema25, color=color.red, title="EMA25")
plot(ema99, color=color.green, title="EMA99")
plot(resistance_level, color=color.orange, style=plot.style_line, title="Resistance")
plot(support_level, color=color.orange, style=plot.style_line, title="Support")
Nuvem do IchimagroNuvem do Ichimagro, indicador feito pra análise de tendências e operações em todos tempos gráficos
Daily True Range (DTR) vs Average True Range (ATR)Overview
The "DTR vs ATR with Color-Coded Percentage" indicator is a powerful volatility analysis tool designed for traders who want to understand daily price movements in the context of historical volatility. It calculates the Daily True Range (DTR)—the raw measure of a single day’s volatility—and compares it to the Average True Range (ATR), which smooths volatility over a user-defined period (default 14 days). The indicator presents this data in an intuitive table, featuring a color-coded percentage that visually represents how the current day’s move (DTR) stacks up against the average volatility (ATR). This helps traders quickly assess whether the current day’s price action is unusually volatile, average, or subdued relative to recent history.
Purpose
Volatility Comparison: Visualize how the current day’s price range (DTR) relates to the average range (ATR) over a specified period.
Decision Support: Identify days with exceptional movement (e.g., breakouts or reversals) versus normal or quiet days, aiding in trade entry/exit decisions.
Risk Management: Gauge daily volatility to adjust position sizing or stop-loss levels based on whether the market is exceeding or falling short of typical movement.
Features
Daily True Range (DTR) Calculation:
Computes the True Range for the current day as the greatest of:
Current day’s High - Low
High - Previous Close
Low - Previous Close
Aggregates data on any timeframe to ensure accurate daily values.
Average True Range (ATR):
Calculates the smoothed average of DTR over a customizable period (default 14 days) using Wilder’s smoothing method.
Updates in real-time as the day progresses.
Timeframe Flexibility: Works on any chart timeframe (e.g., 1-minute, 1-hour) while always calculating DTR and ATR based on daily data.
Color-Coded Display in either compact or table mode
The percentage value is color-coded in the table based on configurable thresholds:
Safe (default 75): Normal range, within typical volatility
Warning: (default 75-125): Above-average volatility.
Danger (default 125): Exceptionally high volatility
Multi-Timeframe Trend Indicator"Introducing the Multi-Timeframe Trend Indicator: Your Key to Comprehensive Market Analysis
Are you looking for a powerful tool to enhance your trading decisions? Our Multi-Timeframe Trend Indicator offers a unique perspective on market trends across five crucial timeframes.
Key Features:
1. Comprehensive Analysis: Simultaneously view trends for H1, H4, D1, W, and M timeframes.
2. Easy-to-Read Display: Color-coded table for instant trend recognition.
3. Proven Strategy: Utilizes the reliable EMA7, SMA20, and SMA200 crossover method.
How It Works:
- Bullish Trend: When EMA7 > SMA20 > SMA200
- Bearish Trend: When EMA7 < SMA20 < SMA200
- Neutral Trend: Any other configuration
Benefits:
- Align your trades with multiple timeframe trends
- Identify potential trend reversals early
- Confirm your trading decisions with a quick glance
Whether you're a day trader or a long-term investor, this indicator provides valuable insights to support your trading strategy. By understanding trends across multiple timeframes, you can make more informed decisions and potentially improve your trading results.
Don't let conflicting timeframes confuse your strategy. Get the full picture with our Multi-Timeframe Trend Indicator today!"
Ronnie's DikFat Attack - Moving Average Angle/Slope PositionRonnie's DikFat Attack - True Moving Average Angle/Slope Position
Overview
This TradingView indicator, written in Pine Script version 5, injects energy into your chart analysis by calculating and displaying the angles of four moving averages (MAs). It empowers you to customize each MA—choosing both type and length—to suit your trading strategy perfectly.
How It Works
1. User Inputs:
Under the “MA Settings” group, the script offers an intuitive interface where you can define four different moving averages. Each MA can be set to one of several types (SMA, EMA, SMMA, VWMA, Hull, WMA, or TEMA) and assigned a specific length (number of bars).
2. Dynamic Moving Average Calculation:
A dedicated function ( getMA ) selects and computes the appropriate moving average using TradingView’s built-in functions (like ta.ema , ta.sma , etc.). This yields four customized MA series based on your inputs.
3. Calculating the Angle of Momentum:
The script employs a robust function ( calcAngle ) that measures the change between consecutive values of each MA to determine its slope. This slope is then converted into an angle in degrees using the arctangent function, providing a clear and vivid depiction of trend strength and direction.
4. Visualizing the Angles:
Each moving average’s angle is plotted with its own distinct color, enhancing visual clarity. A horizontal line at 0° acts as a reference point, marking the divide between upward and downward momentum.
Potential Uses
Trend Analysis:
The angle measurement offers a dynamic perspective on trend strength. Steep positive angles suggest vigorous upward movement, while steep negative angles indicate strong downward trends.
Signal Confirmation:
By comparing the angles of multiple moving averages, you can quickly spot momentum shifts and crossover points, which may serve as powerful entry or exit signals.
Tailored Strategy Customization:
The flexibility to choose various MA types and lengths allows this tool to adapt seamlessly to different timeframes and trading styles, enhancing its usefulness in diverse market conditions.
Crypto USDT VolumeScript Title: USDT Volume
This TradingView indicator calculates a volume metric weighted by price, referred to as "Money." It works by first computing the typical price for each bar as the average of the open, high, low, and close prices. Multiplying this typical price by the bar's volume yields the Money value, which serves as a proxy for the dollar (or USDT) flow during that period.
To improve readability, the script dynamically adjusts the units based on recent data. It examines the highest Money value over the past 100 bars and applies a scaling factor:
Values above 1e9 are scaled to billions (B),
Above 1e6 to millions (M),
Above 1e3 to thousands (K),
Otherwise, no scaling is applied.
The indicator plots these scaled Money values as a column chart. It uses TradingView's default colors—green for bullish bars (where the open is less than the close) and red for bearish bars. Additionally, a label is updated on the last bar to display the current unit used for scaling.
Overall, this script provides a visually intuitive way to track and compare the volume-weighted money flow, making it easier to analyze market activity.
TICK Indikator
English:
The TICK Indicator measures in real time the number of up ticking stocks minus the number of down ticking stocks on the New York Stock Exchange (NYSE). It can display either the current TICK value ("Normal" mode) or the cumulative TICK values over the trading day ("Cumulative" mode). Positive values indicate market strength, while negative values signal weakness. Colored bars visualize momentum: green shades for rising, red for falling values. The zero line acts as a reference between buying and selling pressure.
Interpretation:
> +1000 and/or continuos lows above 0 → strong buying pressure
< -1000 and/or continuos highs below 0 → strong selling pressure
Around 0 → balanced market
Deutsch:
Der TICK Indikator misst in Echtzeit die Anzahl der Aktien, die an der New York Stock Exchange (NYSE) steigen, minus der Anzahl der fallenden Aktien. Der Indikator kann im "Normal"-Modus den aktuellen TICK-Wert anzeigen oder im "Cumulative"-Modus die kumulierten TICK-Werte über den Tag hinweg summieren. Positive Werte deuten auf eine allgemeine Markstärke hin, während negative Werte Schwäche signalisieren. Farbige Balken visualisieren die Dynamik: grüne Töne bei steigenden, rote bei fallenden Werten. Die Nullinie dient als Referenzpunkt zwischen Kauf- und Verkaufsdruck.
Interpretation:
> +1000 und/oder mehrere aufeinander folgende Tiefs über 0 → starker Kaufdruck
< -1000 und/oder mehrere aufeinander folgende Hochs unter 0 → starker Verkaufsdruck
Nahe 0 → ausgeglichener Markt
Trend Trading IndicatorTrend Trading Indicator – Pine Script v5
Overview
The Trend Trading Indicator is designed to help traders identify market trends quickly and effectively. It highlights uptrends and downtrends using Exponential Moving Averages (EMAs) and provides clear buy and sell signals. The indicator is especially useful for detecting insider movements, marketing-driven price pumps, and potential death spirals in crypto and stock markets.
Key Features
✅ Fast-acting trend detection based on EMAs
✅ Clear buy & sell signals marked in blue (BUY) and red (SELL)
✅ Trend zones visually highlighted:
Green for bullish trends (uptrend)
Red for bearish trends (downtrend)
✅ Bold and visible labels for buy and sell signals
✅ Protects against insider selling & marketing hype cycles
✅ Alerts for crossover events
How It Works
Exponential Moving Averages (EMAs)
Short EMA (default: 50-period) represents fast market movement.
Long EMA (default: 100-period) represents slower trends.
When short EMA crosses above long EMA, it signals a buy opportunity.
When short EMA crosses below long EMA, it signals a sell opportunity.
Trend Zones
The area between the two EMAs is color-filled for better trend visualization.
Green Fill: Indicates a bullish trend where short EMA is above long EMA.
Red Fill: Indicates a bearish trend where short EMA is below long EMA.
Buy & Sell Labels
Buy Signal: Blue label “BUY” appears below the candle.
Sell Signal: Red label “SELL” appears above the candle.
Text is in black & bold for better visibility.
Alerts
Custom alerts notify traders when buy or sell conditions occur.
How to Use
Works best in crypto, forex, and stock markets.
Can be used in trend-following or breakout strategies.
Best suited for medium to long-term trades (adjust EMA settings for scalping).
This Trend Trading Indicator helps traders stay ahead of the market by visually identifying strong trends while reducing risks from insider manipulation and death spirals. 🚀
Multi-Timeframe 10-Criteria A-B-C Setup DetectorThis advanced multi-timeframe indicator checks 10 distinct criteria across 5-minute (previous bar) and 1-minute charts to trigger C/B/A setups (8/9/10 criteria).
MACD Strategy//@version=5
strategy("MACD Strategy", overlay=true)
//Macd 参数
fastLength = input(12, title="快线长度")
slowLength = input(26, title="慢线长度")
MACDLength = input(9, title="MACD 信号线长度")
// 计算 MACD
MACD = ta.ema(close, fastLength) - ta.ema(close, slowLength)
aMACD = ta.ema(MACD, MACDLength)
delta = MACD - aMACD
// 计算 EMA(10) 和 MA(20)
ema10 = ta.ema(close, 10)
ma20 = ta.sma(close, 20)
// 在图表上绘制 EMA(10) 和 MA(20),用于调试
plot(ema10, title="EMA 10", color=color.blue, linewidth=2)
plot(ma20, title="MA 20", color=color.red, linewidth=2)
// 实时检查条件
// 检查 EMA(10) 是否高于 MA(20)
bool emaAboveMa = ema10 > ma20
// 检查 MACD 是否在信号线上方,且 MACD 和信号线均在 0 轴下方
bool macdCondition = (MACD > aMACD) and (MACD < 0) and (aMACD < 0)
// 添加调试信息 - 当条件满足时绘制图形
plotshape(emaAboveMa, title="EMA Above MA Condition", size=size.small, text="eam")
plotshape(macdCondition, title="MACD Condition", size=size.small, text="macd")
// 当两个条件都满足时,触发买入操作
if (emaAboveMa and macdCondition)
strategy.entry("多头", strategy.long, comment="买入信号")
// 显示买入信号的标签
label.new(bar_index, high, "买入", textcolor=color.white, style=label.style_label_up, size=size.normal)
// 平仓条件
if (ta.crossunder(delta, 0) and MACD > 0 and aMACD > 0)
strategy.close("MacdLE", comment="Close Long")
//if (ta.crossunder(delta, 0))
// strategy.entry("MacdSE", strategy.short, comment="MacdSE")
//plot(strategy.equity, title="equity", color=color.red, linewidth=2, style=plot.style_areabr)
NSE Index Strategy with Entry/Exit MarkersExplanation of the Code
Trend Filter (200 SMA):
The line trendSMA = ta.sma(close, smaPeriod) calculates the 200‑period simple moving average. By trading only when the current price is above this SMA (inUptrend = close > trendSMA), we aim to trade in the direction of the dominant trend.
RSI Entry Signal:
The RSI is calculated with rsiValue = ta.rsi(close, rsiPeriod). The script checks for an RSI crossover above the oversold threshold using ta.crossover(rsiValue, rsiOversold). This helps capture a potential reversal from a minor pullback in an uptrend.
ATR-Based Exits:
ATR is computed by atrValue = ta.atr(atrPeriod) and is used to set the stop loss and take profit levels:
Stop Loss: stopLossPrice = close - atrMultiplier * atrValue
Take Profit: takeProfitPrice = close + atrMultiplier * atrValue
This dynamic approach allows the exit levels to adjust according to the current market volatility.
Risk and Money Management:
The strategy uses a fixed percentage of equity (10% by default) for each trade. The built‑in commission parameter helps simulate real-world trading costs.
Stock ETF Tracker 2.0The Stock Sector ETF tracker with Indicators is a versatile tool designed to track the performance of sector-specific ETFs relative to the current asset. It automatically identifies the sector of the underlying symbol and displays the corresponding ETF’s price action alongside key technical indicators. This helps traders analyze sector trends and correlations in real time.
---
Key Features
Automatic Sector Detection:
Fetches the sector of the current asset (e.g., "Technology" for AAPL).
Maps the sector to a user-defined ETF (default: SPDR sector ETFs) .
Technical Indicators:
Simple Moving Average (SMA): Tracks the ETF’s trend.
Bollinger Bands: Highlights volatility and potential reversals.
Donchian High (52-Week High): Identifies long-term resistance levels.
SPY Regime Filter: Red background color if SP500 is below 200 day SMA.
Customizable Inputs:
Adjust indicator parameters (length, visibility).
Override default ETFs for specific sectors.
Informative Table:
Displays the current sector and ETF symbol in the bottom-right corner.
---
Input Settings
SMA Settings
SMA Length: Period for calculating the Simple Moving Average (default: 200).
Show SMA: Toggle visibility of the SMA line.
Bollinger Bands Settings
BB Length: Period for Bollinger Bands calculation (default: 20).
BB Multiplier: Standard deviation multiplier (default: 2.0).
Show Bollinger Bands: Toggle visibility of the bands.
Donchian High (52-Week High)
Daily High Length: Days used to calculate the high (default: 252, approx. 1 year).
Show High: Toggle visibility of the 52-week high line.
Sector Selections
Customize ETFs for each sector (e.g., replace XLU with another utilities ETF).
---
Example Use Cases
Trend Analysis: Compare a stock’s price action to its sector ETF’s SMA for trend confirmation.
Volatility Signals: Use Bollinger Bands to spot ETF price squeezes or breakouts.
Sector Strength: Monitor if the ETF is approaching its 52-week high to gauge sector momentum.
Enjoy tracking sector trends with ease! 🚀