KutU @AnlATAbiliyormuyumThis indicator shows support and resistance zones for both long-term and short-term periods. The larger boxes represent zones determined by the long-term timeframe, while the smaller boxes correspond to zones defined by the short-term timeframe. Stay in peace and enjoy.
Bande e canali
Momentum BandsMomentum Bands indicator-->technical tool that measures the rate of price change and surrounds this momentum with adaptive bands to highlight overbought and oversold zones. Unlike Bollinger Bands, which track price, these bands track momentum itself, offering a unique view of market strength and exhaustion points. At its core, it features a blue momentum line that calculates the rate of change over a set period, an upper red band marking dynamic resistance created by adding standard deviations to the momentum average, a lower green band marking dynamic support by subtracting standard deviations, and a gray middle line representing the average of momentum as a central anchor. When the momentum line touches or moves beyond the upper red band, it often signals that the market may be overbought and a pullback or reversal could follow; traders might lock in profits or watch for short setups. Conversely, when it drops below the lower green band, it can suggest an oversold market primed for a bounce, prompting traders to look for buying opportunities. If momentum remains between the bands, it typically indicates balanced conditions where waiting for stronger signals at the extremes is wise. The indicator can be used in contrarian strategies—buying near the lower band and selling near the upper—or in trend-following setups by waiting for momentum to return toward the centerline before entering trades. For stronger confirmation, traders often combine it with volume spikes, support and resistance analysis, or other trend tools, and it’s useful to check multiple timeframes to spot consistent patterns. Recommended settings vary: short-term traders might use a 7–10 period momentum with 14-period bands; medium-term traders might keep the default 14-period momentum and 20-period bands; while long-term analysis might use 21-period momentum and 50-period bands. Visually, background colors help spot extremes: red for strong overbought, green for strong oversold, and no color for normal markets, alongside reference lines at 70, 30, and 0 to guide traditional overbought, oversold, and neutral zones. Typical bullish signals include momentum rebounding from the lower band, crossing back above the middle after being oversold, or showing divergence where price makes new lows but momentum doesn’t. Bearish signals might appear when momentum hits the upper band and weakens, drops below the middle after being overbought, or price makes new highs while momentum fails to follow. The indicator tends to work best in mean-reverting or sideways markets rather than strong trends, where overbought and oversold conditions tend to repeat.
Step-MA Baseline (with optional smoother)poor man trackline, it uses the ma20 and smooth it out to signal trends
Bitcoin Power Law ModelBitcoin Power Law Model with Cycle Predictions
Scientific Price Modeling for Bitcoin
This indicator implements **Dr. Giovanni Santostasi's Bitcoin Power Law Theory** - a discovery that Bitcoin's price follows mathematical laws similar to natural phenomena. Unlike traditional financial models, this treats Bitcoin as a scale-invariant system that grows predictably over time.
What Makes This Special
Dr. Santostasi, an astrophysicist who studied gravitational waves, discovered that Bitcoin's price forms a perfect straight line when plotted on a log-log scale over its entire 15-year history. This isn't just another technical indicator - it's a fundamental law that has held true through multiple 80%+ crashes and recoveries.
Core Features
Power Law Model
- Orange Line: The power law trajectory showing Bitcoin's long-term growth path
- Yellow Line: Fair value (geometric mean between support and resistance)
- Green/Red Bands: Support and resistance levels that have historically contained price movements
- Band Position %: Shows exactly where price sits within the power law channel (0-100%)
How to Use It
For Long-term Investors
1. Accumulate when price is near the green support line (band position < 20%)
2. Hold when price is between the bands
3. Consider profits when approaching red resistance (band position > 80%)
4. Never panic - the model shows $30K+ is now the permanent floor
Key Metrics to Watch
- **Band Position: <20% = Oversold, >80% = Overbought
- Fair Value: Price above = Overvalued, below = Undervalued
- Support Line: Breaking below suggests model invalidation
Current Cycle Projections
Based on the November 2022 bottom at ~$15,500:
- Cycle Peak: ~$155,000-$230,000 (October 2025)
- Next Bottom: ~$70,000-$100,000 (October 2026)
- Long-term: $1 million by 2033 (power law projection)
Customizable Settings
Model Parameters
- Intercept & Slope: Fine-tune the power law formula
- Band Offsets: Adjust support/resistance distances
Display Options
- Toggle each visual element on/off
- Show/hide future projections
- Enable/disable cycle analysis
- Customize halving markers
Understanding the Math
The model uses the formula: **Price = 10^(A + B × log10(days since genesis))**
Where:
- A = -17.01 (intercept)
- B = 5.82 (slope)
- Days counted from Bitcoin's genesis block (Jan 3, 2009)
This creates parallel support/resistance lines in log-log space that have contained Bitcoin's price for 15+ years.
Important
1.Not Financial Advice: This is a mathematical model, not a guarantee
2. Long-term Focus: Best suited for macro analysis, not day trading
3. Model Limitations: Past performance doesn't ensure future results
4. Volatility Expected: 50-80% drawdowns are normal within the model
Background
Dr. Giovanni Santostasi discovered this model while analyzing Bitcoin through the lens of physics. He found that Bitcoin behaves more like a city or organism than a financial asset, growing according to universal power laws found throughout
Bitcoin Stock-to-Flow Model Price Bands# Bitcoin Stock-to-Flow Model Price Bands
Overview
This indicator implements the famous Stock-to-Flow (S2F) model created by PlanB (@100trillionUSD), which uses Bitcoin's scarcity to predict its long-term value. The S2F model has gained significant attention for its historical accuracy in capturing Bitcoin's price movements across multiple market cycles.
What is Stock-to-Flow?
Stock-to-Flow is a ratio that measures scarcity by dividing the current supply (stock) by the annual production (flow). The model suggests that as Bitcoin becomes scarcer through halving events, its value should increase proportionally.
This indicator features:
Dynamic S2F Calculation
- Automatically calculates Bitcoin's current supply based on block height
- Adjusts for halving events (every 210,000 blocks)
- Updates the S2F ratio in real-time
Visual Elements
- Orange Line: S2F model price based on the formula: Price = 0.4 × S2F³
- Confidence Bands: Upper (red) and lower (green) bands showing expected price ranges
- Colored Candles: Green when above model price, red when below
- Info Table: Displays current S2F ratio, model price, actual price, and price multiple
Customizable Parameters
- Model Coefficient: Adjust the multiplier (default: 0.4)
- Model Exponent: Modify the power factor (default: 3.0)
- Band Width: Control confidence band spread (1-5 standard deviations)
- Display Options: Toggle individual elements on/off
Built-in Alerts
- Price crossing above/below S2F model price
- Price exceeding upper/lower confidence bands
How to Use
1. Trend Identification: When price is above the orange S2F line, Bitcoin may be overvalued; below suggests undervaluation
2. Cycle Analysis: The model steps up at each halving, creating distinct price "floors"
3. Risk Management: Use confidence bands to identify extreme deviations from the model
4. Long-term Perspective: Best suited for macro analysis rather than short-term trading
Important to understand:
This is a model, not a guarantee. The S2F model:
- Assumes scarcity is the primary driver of value
- Doesn't account for demand-side factors
- Has shown deviations during certain market conditions
- Should be used alongside other analysis methods
Model Performance
Historically, the S2F model has captured major Bitcoin price movements:
- 2013 Bull Run: Price followed model predictions
- 2017 Peak: Reached model targets
- 2021 Cycle: Initially tracked, then deviated
- 2024-2025: Model suggests $500k-$1M potential
Technical Details
- Uses logarithmic regression similar to the original S2F model
- Accounts for "lost" coins (est. 1M BTC from early mining)
- Implements dynamic supply calculation through halving cycles
- Confidence bands use log-normal distribution
Best Timeframes
- Weekly/Monthly: Ideal for long-term trend analysis
Credits
Based on the Stock-to-Flow model by PlanB (@100trillionUSD)
Original article: "Modeling Bitcoin's Value with Scarcity" (2019)
Bollinger Bands📊 Bollinger Bands Strategy: Ride the Waves of Volatility 🌊
Bollinger Bands are a powerful tool to identify overbought and oversold conditions, volatility breakouts, and price reversals. This strategy uses:
🔹 Middle Band – 20-period simple moving average
🔹 Upper & Lower Bands – 2 standard deviations away from the SMA
💡 Strategy Logic:
Buy Entry: When price closes below the lower band and RSI < 30 → Expect mean reversion.
Sell Entry: When price closes above the upper band and RSI > 70 → Possible pullback.
Exit: Near middle band or opposite band.
📈 You can also use Bollinger Band squeezes to detect upcoming breakouts. Less distance = low volatility → Expansion = potential big move!
🧠 Great for swing trading or intraday scalping with proper risk management.
EMA 6/16/55/100/200 ฺBy Smurojคำอธิบายเป็นภาษาไทย
ชุด EMA นี้ประกอบด้วยเส้นค่าเฉลี่ยเคลื่อนที่แบบเอ็กซ์โปเนนเชียล (EMA) ระยะเวลาต่าง ๆ ซึ่งถูกนำมาใช้เพื่อวิเคราะห์แนวโน้มราคาในระยะต่าง ๆ ดังนี้:
EMA 6 และ 16: ใช้สำหรับดูแนวโน้มระยะสั้นและการเปลี่ยนแปลงราคาที่รวดเร็ว
EMA 55: เป็นแนวโน้มระยะกลาง
EMA 100 และ 200: เป็นแนวโน้มระยะยาว ซึ่งช่วยดูภาพรวมของแนวโน้มตลาดในระดับลึก
การใช้งานในการเทรด:
ถ้าราคาอยู่เหนือ EMA ระยะต่าง ๆ แสดงถึงแนวโน้มขาขึ้น
ถ้าราคาอยู่ต่ำกว่า EMA ระยะต่าง ๆ แสดงถึงแนวโน้มขาลง
การตัดกันของ EMA สั้นและยาว เช่น EMA 6 ตัด EMA 16 ขึ้นบน อาจเป็นสัญญาณซื้อ
การตัดกันในทางตรงกันข้าม อาจเป็นสัญญาณขาย
การใช้หลายเส้นช่วยยืนยันแนวโน้มและลดความผิดพลาดในการตัดสินใจ
English Explanation
This EMA set consists of various Exponential Moving Average lines over different periods, which are used to analyze price trends across various timeframes:
EMA 6 and 16: For short-term trend analysis and quick price changes.
EMA 55: Represents a medium-term trend.
EMA 100 and 200: Indicate long-term trends, helping to view the overall market direction.
How to use in trading:
When price is above these EMA lines, it suggests an uptrend.
When price is below these EMA lines, it indicates a downtrend.
Crossovers between short and longer EMAs (e.g., EMA 6 crossing above EMA 16) can signal buy opportunities.
Conversely, crossovers downward can signal sell opportunities.
Using multiple EMA lines helps confirm the trend and reduce false signals.
EMA 6/16/55/100/200คำอธิบายเป็นภาษาไทย
ชุด EMA นี้ประกอบด้วยเส้นค่าเฉลี่ยเคลื่อนที่แบบเอ็กซ์โปเนนเชียล (EMA) ระยะเวลาต่าง ๆ ซึ่งถูกนำมาใช้เพื่อวิเคราะห์แนวโน้มราคาในระยะต่าง ๆ ดังนี้:
EMA 6 และ 16: ใช้สำหรับดูแนวโน้มระยะสั้นและการเปลี่ยนแปลงราคาที่รวดเร็ว
EMA 55: เป็นแนวโน้มระยะกลาง
EMA 100 และ 200: เป็นแนวโน้มระยะยาว ซึ่งช่วยดูภาพรวมของแนวโน้มตลาดในระดับลึก
การใช้งานในการเทรด:
ถ้าราคาอยู่เหนือ EMA ระยะต่าง ๆ แสดงถึงแนวโน้มขาขึ้น
ถ้าราคาอยู่ต่ำกว่า EMA ระยะต่าง ๆ แสดงถึงแนวโน้มขาลง
การตัดกันของ EMA สั้นและยาว เช่น EMA 6 ตัด EMA 16 ขึ้นบน อาจเป็นสัญญาณซื้อ
การตัดกันในทางตรงกันข้าม อาจเป็นสัญญาณขาย
การใช้หลายเส้นช่วยยืนยันแนวโน้มและลดความผิดพลาดในการตัดสินใจ
English Explanation
This EMA set consists of various Exponential Moving Average lines over different periods, which are used to analyze price trends across various timeframes:
EMA 6 and 16: For short-term trend analysis and quick price changes.
EMA 55: Represents a medium-term trend.
EMA 100 and 200: Indicate long-term trends, helping to view the overall market direction.
How to use in trading:
When price is above these EMA lines, it suggests an uptrend.
When price is below these EMA lines, it indicates a downtrend.
Crossovers between short and longer EMAs (e.g., EMA 6 crossing above EMA 16) can signal buy opportunities.
Conversely, crossovers downward can signal sell opportunities.
Using multiple EMA lines helps confirm the trend and reduce false signals.
MACD Platinum + QQE ADV Jan 2025A two in one indicator where you can either choose to display either the MACD Platinum (zero lag MACD) or the QQE Adv.
QMP Filter Jan 2025The QMP Filter itself are the red/blue dots displayed on the price chart. These are a combination of the MACD Platinum (zero lag MACD) and the QQE Adv. When they are in sync, then a QMP Filter dot is presented.
The indicator also includes the option of adding multiple Moving Averages and Bollinger Bands to the price chart if required. Cheers. Jim
FİBO FİNAL An Indicator Suitable for Further Development
OK3 Final Buy
S1 Take Profit
S2 Close Half of the Position
S3 Close the Position
Squeeze with DojiThis script indicates Bollinger band squeeze into Keltner channels to identify the contraction of price and Doji candle formation, potentially leading up to the momentum expansion in price.
Add your preferable volume or price indicators on top of this volatility contraction indicator.
Feel free to use and share your feedback.
لعلي بابا على ساعة Moving averages indicator for the 10 and 20 averages, relative strength index, and Bollinger Bands Moving averages indicator for the 10 and 20 averages, relative strength index, and Bollinger Bands
Makki MultiEdge Analyzer 2000This script combines Bollinger Band interactions, RSI momentum confirmation, EMA crossovers, and divergence detection to generate filtered BUY signals. It uses 5-minute and 15-minute timeframe logic to improve timing and reduce false entries.
### 🔹 BUY signal logic:
A BUY label will only appear when:
• Price is near the lower Bollinger Band
• RSI shows a rebound or is climbing from oversold zones
• There is a strong bullish candle, a golden cross (EMA), or a positive divergence
• AND no overbought/exit filter is active
### 💎 Entry filter (diamond):
Appears when a clean bounce is detected on the 5-minute chart.
This is **not a BUY** but a preparation signal — useful to monitor for an upcoming opportunity.
### ⛔ Exit filter:
Triggers when 15m RSI is overbought (>68), price touches the 15m upper Bollinger Band, and 5m momentum weakens.
Blocks BUY signals and helps avoid entries during overextended moves.
### 🔺/🔻 Mild Support/Resistance markers:
- **🔺 Green upward triangle:** appears when RSI rebound or mild support conditions exist, but not enough for a BUY
- **🔻 Red downward triangle:** appears when bearish momentum, EMA crossdown, overbought RSI, or negative divergence is detected
### ❌ RSI Warnings:
- **Orange X above the bar:** RSI > 75 (overbought warning)
- **Orange X below the bar:** RSI < 25 (oversold warning)
### 🧠 Usage recommendation:
- Wait for a 💎 as early preparation
- Enter only if a BUY signal follows with no ⛔ warning present
- Avoid BUYs that appear after ⛔ or during RSI > 75 (orange X) unless very strong reversal confirmation exists
- 🔺 triangles can help monitor early support but are not sufficient alone
### 🕒 Timeframe:
- Best used on 5-minute chart
- Filtering logic pulls RSI and Bollinger data from 5m and 15m timeframes
- Higher timeframes (15m–1H) can be used for overall trend direction
All alerts are included for: BUY, entry filter (💎), exit warning (⛔), RSI warnings (❌), and support/resistance markers (🔺/🔻).
This script is for educational purposes only and does not constitute financial advice.
Ichimoku Cloud MAThis chart has a combination of the Ichimoku cloud and Moving Average. This is solely for education and I am not responsible for any losses to users' investments.
Keltner BandWidthThis script measures the bandwidth of Keltner Channels using the same formula as is typical for Bollinger Bandwidth - (Upper band - Lower Band)/Basis where basis is the 20 period moving average. In the case of Keltner Channels, the basis uses the exponential moving average and a 10-period Average True Range as the multiplier. My use case for the indicator is to compare Bollinger Bandwidth to three different KC parameters (multipliers of 1x, 1.5x and 2x) for the identification of squeeze conditions used in the Simpler Trading Squeeze Pro indicator.
D-LevelsThis indicator accepts a comma-separated list of price ranges as input and visualizes each range as a distinct zone on the chart, using randomized colors for distinction.
Ai Golden Support and Resistance 🔰 Ai Golden Support & Resistance — by GoldenCryptoSignals
This advanced tool automatically identifies high-probability support and resistance zones using adaptive smart analysis driven by price action behavior and dynamic market conditions. It provides AI-enhanced detection of potential reversal areas, offering traders precise levels to watch for possible entries, exits, or stop placements.
🧠 Key Features:
AI-style Adaptive Zones: Dynamically generated support and resistance levels based on changing volatility and price behavior.
Breakout & Retest Visualization: Highlights critical price levels and potential reaction zones when the market breaks key levels.
Explosive Move Detection: Alerts traders to areas where the price previously made strong directional moves, indicating possible institutional footprints.
Flexible Risk Profiles: Choose between High, Medium, or Low Risk zone sensitivity — adapt the algorithm to your trading style.
Smart Zone Persistence: Zones remain visible until invalidated, helping traders visually track active supply and demand levels.
Auto Labeling and Color Coding: Easy-to-understand visuals showing market structure, zone type, and breakout signals.
Optimized for Clarity: Minimal chart clutter with elegant layout, auto-zoning boxes, and breakout signals that assist decision-making.
🔎 Use Cases:
Spot institutional levels where price is likely to react.
Use zones for confluence with other strategies or indicators.
Anticipate potential breakout or fakeout areas.
Track active vs inactive zones dynamically.
⚠️ Disclaimer:
This script is designed to assist in analysis and does not provide financial advice. Always manage your own risk and test any tool before using it in live trading. This is a closed-source indicator developed by GoldenCryptoSignals.
Cubic Regression with Rainbow Grid (Adaptive StDev)Cubic Regression with Rainbow Channel
Description
The Cubic Regression with Rainbow Channel is an advanced technical analysis tool designed to identify trends and measure market volatility. It plots a cubic regression trendline surrounded by a "rainbow" of quantile bands.
Its primary feature is a unique adaptive volatility model. Instead of using a single period for standard deviation, it blends a long-term (stable) and a short-term (responsive) deviation. The user can control the weight between these two, allowing for fine-tuning of the channel's sensitivity to recent volatility changes.
How to Use and Recommendations
This indicator can be used for trend analysis, volatility assessment, and generating trading signals.
1. Trend Identification:
The central white line represents the calculated cubic regression trend.
Uptrend: The line curves upwards.
Downtrend: The line curves downwards.
Consolidation: The line moves sideways.
The curve's angle indicates the trend's strength.
2. Volatility Analysis:
The width of the rainbow is a direct measure of market volatility.
Wide Channel (High Volatility): Indicates significant price movement and uncertainty. Be cautious, as prices can swing wildly.
Narrow Channel (Low Volatility): Signals a period of consolidation or low market activity. Often, a "squeeze" (a very narrow channel) precedes a strong breakout.
3. Trading Signals:
Mean Reversion (Primary Strategy):
Sell Signal: When the price reaches the upper, "hot" bands (yellow, orange, red), it is considered overbought or overextended. Look for a potential reversal back towards the central white line.
Buy Signal: When the price touches the lower, "cold" bands (aqua, navy, purple), it is considered oversold. Look for a potential bounce back towards the central trendline.
Breakout Confirmation:
If the price consistently closes outside the outer bands (red or purple), especially as the channel is widening, it may signal the start of a very strong new trend, invalidating the mean-reversion signal.
4. Key Recommendations:
Always Use Confirmation: Do not use this indicator in isolation. Confirm its signals with other tools like RSI for momentum, MACD for trend confirmation, or Volume analysis.
Tune the Parameters:
Regression Period: Adjust this to fit the character of the asset. A longer period creates a smoother, more stable trendline suitable for long-term analysis. A shorter period makes it more responsive to recent price action.
Short StDev Weight (%): This is the most important setting. Start with a value around 20-40%.
Increase the weight to make the channel react faster to volatility spikes (good for short-term trading).
Decrease the weight for a smoother, more stable channel that filters out market noise (better for trend-following).
Context is King: The indicator is most reliable in markets that tend to revert to a mean. In a very strong, one-directional trend, mean-reversion signals may fail repeatedly.
DXTRADE//@version=5
indicator(title="DXTRADE", shorttitle="", overlay=true)
// التأكد من أن السوق هو XAUUSD فقط
isGold = syminfo.ticker == "XAUUSD"
// حساب شموع الهايكن آشي
haClose = (open + high + low + close) / 4
var float haOpen = na
haOpen := na(haOpen ) ? open : (haOpen + haClose ) / 2
haHigh = math.max(high, math.max(haOpen, haClose))
haLow = math.min(low, math.min(haOpen, haClose))
// إعداد المعلمات
atr_len = input.int(3, "ATR Length", group="SuperTrend Settings")
fact = input.float(4, "SuperTrend Factor", group="SuperTrend Settings")
adxPeriod = input(2, title="ADX Filter Period", group="Filtering Settings")
adxThreshold = input(2, title="ADX Minimum Strength", group="Filtering Settings")
// حساب ATR
volatility = ta.atr(atr_len)
// حساب ADX يدويًا
upMove = high - high
downMove = low - low
plusDM = upMove > downMove and upMove > 0 ? upMove : 0
minusDM = downMove > upMove and downMove > 0 ? downMove : 0
smoothedPlusDM = ta.rma(plusDM, adxPeriod)
smoothedMinusDM = ta.rma(minusDM, adxPeriod)
smoothedATR = ta.rma(volatility, adxPeriod)
plusDI = (smoothedPlusDM / smoothedATR) * 100
minusDI = (smoothedMinusDM / smoothedATR) * 100
dx = math.abs(plusDI - minusDI) / (plusDI + minusDI) * 100
adx = ta.rma(dx, adxPeriod)
// حساب SuperTrend
pine_supertrend(factor, atr) =>
src = hl2
upperBand = src + factor * atr
lowerBand = src - factor * atr
prevLowerBand = nz(lowerBand )
prevUpperBand = nz(upperBand )
lowerBand := lowerBand > prevLowerBand or close < prevLowerBand ? lowerBand : prevLowerBand
upperBand := upperBand < prevUpperBand or close > prevUpperBand ? upperBand : prevUpperBand
int _direction = na
float superTrend = na
prevSuperTrend = superTrend
if na(atr )
_direction := 1
else if prevSuperTrend == prevUpperBand
_direction := close > upperBand ? -1 : 1
else
_direction := close < lowerBand ? 1 : -1
superTrend := _direction == -1 ? lowerBand : upperBand
= pine_supertrend(fact, volatility)
// فلتر التوقيت (من 8 صباحاً إلى 8 مساءً بتوقيت العراق UTC+3)
withinSession = time >= timestamp("Asia/Baghdad", year, month, dayofmonth, 8, 0) and time <= timestamp("Asia/Baghdad", year, month, dayofmonth, 20, 0)
// إشارات الدخول مع فلتر ADX والتوقيت
validTrend = adx > adxThreshold
longEntry = ta.crossunder(dir, 0) and isGold and validTrend and withinSession
shortEntry = ta.crossover(dir, 0) and isGold and validTrend and withinSession
// وقف الخسارة والهدف
pipSize = syminfo.mintick * 10
takeProfit = 150 * pipSize
stopLoss = 150 * pipSize
// حساب الأهداف والستوب بناءً على شمعة الدخول (haClose للشمعة الحالية)
longTP = haClose + takeProfit
longSL = haClose - stopLoss
shortTP = haClose - takeProfit
shortSL = haClose + stopLoss
// إشارات الدخول
plotshape(series=longEntry, location=location.belowbar, color=color.green, style=shape.labelup, title="BUY")
plotshape(series=shortEntry, location=location.abovebar, color=color.red, style=shape.labeldown, title="SELL")
// رسم خطوط الأهداف ووقف الخسارة عند بداية الشمعة التالية للإشارة
if longEntry
line.new(bar_index, haClose + takeProfit, bar_index + 10, haClose + takeProfit, color=color.green, width=2, style=line.style_dashed)
line.new(bar_index, haClose - stopLoss, bar_index + 10, haClose - stopLoss, color=color.red, width=2, style=line.style_dashed)
if shortEntry
line.new(bar_index, haClose - takeProfit, bar_index + 10, haClose - takeProfit, color=color.green, width=2, style=line.style_dashed)
line.new(bar_index, haClose + stopLoss, bar_index + 10, haClose + stopLoss, color=color.red, width=2, style=line.style_dashed)
// إضافة تنبيهات
alertcondition(longEntry, title="Buy Alert", message="Gold Scalping - Buy Signal!")
alertcondition(shortEntry, title="Sell Alert", message="Gold Scalping - Sell Signal!")