B3 20/50 MeanSimple MA's 20 and 50 are averaged to produce a mean MA line. I like the smoothness of it, and it can help you stay in a trade in the slow moving trends. Also if you start to see a large cloud in your favor, it could be a great time take the profits.
在腳本中搜尋"黄金近20年走势"
ShareGenius Swing Trading (SST) 20 days low
20 days high
target to set
special thanks to Shri Mahesh Chander Kaushik and Shri Krishan
Bullish & Bearish Reversal Pattern with Sequential Bars20 Bollinger Bands and custom Stochasti_MTM Setup
Both long and short reversal signals.
EMA/SMA + Multi-Timeframe Dashboard (Vertical)20/50 ema and 200 sma
The EMA SMA Trading Indicator combines the power of Exponential Moving Averages (EMA) and Simple Moving Averages (SMA) to help traders identify trends, reversals, and key entry/exit points.
Features:
Dual Moving Averages: Tracks both EMA and SMA to provide a balanced view of short-term and long-term market trends.
Customizable Periods: Allows users to set unique periods for EMA and SMA to suit their trading style and timeframe (e.g., day trading, swing trading, or investing).
Cross Alerts: Highlights EMA and SMA crossover points, which often indicate potential buy or sell signals.
Color-Coded Lines: Visual differentiation between EMA (dynamic and responsive) and SMA (smooth and lagging) for better readability.
Multi-Timeframe Compatibility: Suitable for scalping, intraday trading, and long-term analysis.
Usage:
Trend Confirmation: When the EMA is above the SMA, it signals a bullish trend; when it is below the SMA, it signals a bearish trend.
Crossover Strategy: Use crossovers as potential buy (EMA crosses above SMA) or sell (EMA crosses below SMA) signals.
Dynamic Support/Resistance: EMA can act as short-term support/resistance, while SMA represents long-term levels.
This indicator is perfect for traders who want to combine EMA's speed with SMA's stability for improved decision-making in volatile markets. Customizable alerts and visual cues make it user-friendly for beginners and experienced traders.
Make informed decisions and take your trading to the next level with the EMA SMA Trading Indicator!
6 Bollinger Bands (1.5 thru 4)20 period SMA Bollinger Bands with the following standard deviations: 1.5 2 2.5 3 3.5 4
[e2] Color Gradient Function20 step red/green gradient function
The color gradient function allow colorize any source in 5% steps.
Define the source, minimum and maximum value (constant or , for example, bb (or any other channel)).
Rounded Bottom Breakout Strategy Moving Averages20-day SMA , 34-day EMA , 50-day SMA and 200-day SMA moving average indicator based on Rick Saddler's Rounded Bottom Reversal Breakout Strategy
Noro's Fishnet Strategy20 lines are JMA. Green color - a uptrend. Red color - a downtrend.
Color filter
If this checkbox is chosen, then long positions will be open only if a red candle. Short positions will open if a green candle.
If this checkbox is not chosen, then positions will open at change of a trend. Color of a candle will not matter.
20 years old Turtles strategy still work!!original idea from «Way of the Turtle: The Secret Methods that Turned Ordinary People into Legendary Traders» (2007) CURTIS FAITH
Market Electromagnetic Field [The_lurker]Market Electromagnetic Field
An innovative analytical indicator that presents a completely new model for understanding market dynamics, inspired by the laws of electromagnetic physics — but it's not a rhetorical metaphor, rather a complete mathematical system.
Unlike traditional indicators that focus on price or momentum, this indicator portrays the market as a closed physical system, where:
⚡ Candles = Electric charges (positive at bullish close, negative at bearish)
⚡ Buyers and Sellers = Two opposing poles where pressure accumulates
⚡ Market tension = Voltage difference between the poles
⚡ Price breakout = Electrical discharge after sufficient energy accumulation
█ Core Concept
Markets don't move randomly, but follow a clear physical cycle:
Accumulation → Tension → Discharge → Stabilization → New Accumulation
When charges accumulate (through strong candles with high volume) and exceed a certain "electrical capacitance" threshold, the indicator issues a "⚡ DISCHARGE IMMINENT" alert — meaning a price explosion is imminent, giving the trader an opportunity to enter before the move begins.
█ Competitive Advantage
- Predictive forecasting (not confirmatory after the event)
- Smart multi-layer filtering reduces false signals
- Animated 3D visual representation makes reading price conditions instant and intuitive — without need for number analysis
█ Theoretical Physical Foundation
The indicator doesn't use physical terms for decoration, but applies mathematical laws with precise market adjustments:
⚡ Coulomb's Law
Physics: F = k × (q₁ × q₂) / r²
Market: Field Intensity = 4 × norm_positive × norm_negative
Peaks at equilibrium (0.5 × 0.5 × 4 = 1.0), and decreases at dominance — because conflict increases at parity.
⚡ Ohm's Law
Physics: V = I × R
Market: Voltage = norm_positive − norm_negative
Measures balance of power:
- +1 = Absolute buying dominance
- −1 = Absolute selling dominance
- 0 = Balance
⚡ Capacitance
Physics: C = Q / V
Market: Capacitance = |Voltage| × Field Intensity
Represents stored energy ready for discharge — increases with bias combined with high interaction.
⚡ Electrical Discharge
Physics: Occurs when exceeding insulation threshold
Market: Discharge Probability = min(Capacitance / Discharge Threshold, 1.0)
When ≥ 0.9: "⚡ DISCHARGE IMMINENT"
📌 Key Note:
Maximum capacitance doesn't occur at absolute dominance (where field intensity = 0), nor at perfect balance (where voltage = 0), but at moderate bias (±30–50%) with high interaction (field intensity > 25%) — i.e., in moments of "pressure before breakout".
█ Detailed Calculation Mechanism
⚡ Phase 1: Candle Polarity
polarity = (close − open) / (high − low)
- +1.0: Complete bullish candle (Bullish Marubozu)
- −1.0: Complete bearish candle (Bearish Marubozu)
- 0.0: Doji (no decision)
- Intermediate values: Represent the ratio of candle body to its range — reducing the effect of long-shadow candles
⚡ Phase 2: Volume Weight
vol_weight = volume / SMA(volume, lookback)
A candle with 150% of average volume = 1.5x stronger charge
⚡ Phase 3: Adaptive Factor
adaptive_factor = ATR(lookback) / SMA(ATR, lookback × 2)
- In volatile markets: Increases sensitivity
- In quiet markets: Reduces noise
- Always recommended to keep it enabled
⚡ Phase 4–6: Charge Accumulation and Normalization
Charges are summed over lookback candles, then ratios are normalized:
norm_positive = positive_charge / total_charge
norm_negative = negative_charge / total_charge
So that: norm_positive + norm_negative = 1 — for easier comparison
⚡ Phase 7: Field Calculations
voltage = norm_positive − norm_negative
field_intensity = 4 × norm_positive × norm_negative × field_sensitivity
capacitance = |voltage| × field_intensity
discharge_prob = min(capacitance / discharge_threshold, 1.0)
█ Settings
⚡ Electromagnetic Model
Lookback Period
- Default: 20
- Range: 5–100
- Recommendations:
- Scalping: 10–15
- Day Trading: 20
- Swing: 30–50
- Investing: 50–100
Discharge Threshold
- Default: 0.7
- Range: 0.3–0.95
- Recommendations:
- Speed + Noise: 0.5–0.6
- Balance: 0.7
- High Accuracy: 0.8–0.95
Field Sensitivity
- Default: 1.0
- Range: 0.5–2.0
- Recommendations:
- Amplify Conflict: 1.2–1.5
- Natural: 1.0
- Calm: 0.5–0.8
Adaptive Mode
- Default: Enabled
- Always keep it enabled
🔬 Dynamic Filters
All enabled filters must pass for discharge signal to appear.
Volume Filter
- Condition: volume > SMA(volume) × vol_multiplier
- Function: Excludes "weak" candles not supported by volume
- Recommendation: Enabled (especially for stocks and forex)
Volatility Filter
- Condition: STDEV > SMA(STDEV) × 0.5
- Function: Ignores sideways stagnation periods
- Recommendation: Always enabled
Trend Filter
- Condition: Voltage alignment with fast/slow EMA
- Function: Reduces counter-trend signals
- Recommendation: Enabled for swing/investing only
Volume Threshold
- Default: 1.2
- Recommendations:
- 1.0–1.2: High sensitivity
- 1.5–2.0: Exclusive to high volume
🎨 Visual Settings
Settings improve visual reading experience — don't affect calculations.
Scale Factor
- Default: 600
- Higher = Larger scene (200–1200)
Horizontal Shift
- Default: 180
- Horizontal shift to the left — to focus on last candle
Pole Size
- Default: 60
- Base sphere size (30–120)
Field Lines
- Default: 8
- Number of field lines (4–16) — 8 is ideal balance
Colors
- Green/Red/Blue/Orange
- Fully customizable
█ Visual Representation: A Visual Language for Diagnosing Price Conditions
✨ Design Philosophy
The representation isn't "decoration", but a complete cognitive model — each element carries information, and element interaction tells a complete story.
The brain perceives changes in size, color, and movement 60,000 times faster than reading numbers — so you can "sense" the change before your eye finishes scanning.
═════════════════════════════════════════════════════════════
🟢 Positive Pole (Green Sphere — Left)
═════════════════════════════════════════════════════════════
What does it represent?
Active buying pressure accumulation — not just an uptrend, but real demand force supported by volume and volatility.
● Dynamic Size
Size = pole_size × (0.7 + norm_positive × 0.6)
- 70% of base size = No significant charge
- 130% of base size = Complete dominance
- The larger the sphere: Greater buyer dominance, higher probability of bullish continuation
Size Interpretation:
- Large sphere (>55%): Strong buying pressure — Buyers dominate
- Medium sphere (45–55%): Relative balance with buying bias
- Small sphere (<45%): Weak buying pressure — Sellers dominate
● Lighting and Transparency
- 20% transparency (when Bias = +1): Pole currently active — Bullish direction
- 50% transparency (when Bias ≠ +1): Pole inactive — Not the prevailing direction
Lighting = Current activity, while Size = Historical accumulation
● Pulsing Inner Glow
A smaller sphere pulses automatically when Bias = +1:
inner_pulse = 0.4 + 0.1 × sin(anim_time × 3)
Symbolizes continuity of buy order flow — not static dominance.
● Orbital Rings
Two rings rotating at different speeds and directions:
- Inner: 1.3× sphere size — Direct influence range
- Outer: 1.6× sphere size — Extended influence range
Represent "influence zone" of buyers:
- Continuous rotation = Stability and momentum
- Slowdown = Momentum exhaustion
● Percentage
Displayed below sphere: norm_positive × 100
- >55% = Clear dominance
- 45–55% = Balance
- <45% = Weakness
═════════════════════════════════════════════════════════════
🔴 Negative Pole (Red Sphere — Right)
═════════════════════════════════════════════════════════════
What does it represent?
Active selling pressure accumulation — whether cumulative selling (smart distribution) or panic selling (position liquidation).
● Visual Dynamics
Same size, lighting, and inner glow mechanism — but in red.
Key Difference:
- Rotation is reversed (counter-clockwise)
- Visually distinguishes "buy flow" from "sell flow"
- Allows reading direction at a glance — even for colorblind users
📌 Pole Reading Summary:
🟢 Large + Bright green sphere = Active buying force
🔴 Large + Bright red sphere = Active selling force
🟢🔴 Both large but dim = Energy accumulation (before discharge)
⚪ Both small = Stagnation / Low liquidity
═════════════════════════════════════════════════════════════
🔵 Field Lines (Curved Blue Lines)
═════════════════════════════════════════════════════════════
What do they represent?
Energy flow paths between poles — the arena where price battle is fought.
● Number of Lines
4–16 lines (Default: 8)
More lines: Greater sense of "interaction density"
● Arc Height
arc_h = (i − half_lines) × 15 × field_intensity × 2
- High field intensity = Highly elevated lines (like waves)
- Low intensity = Nearly straight lines
● Oscillating Transparency
transp = 30 + phase × 40
where phase = sin(anim_time × 2 + i × 0.5) × 0.5 + 0.5
Creates illusion of "flowing current" — not static lines
● Asymmetric Curvature
- Upper lines curve upward
- Lower lines curve downward
- Adds 3D depth and shows "pressure" direction
⚡ Pro Tip:
When you see lines suddenly "contract" (straighten), while both spheres are large — this is an early indicator of impending discharge, because the interaction is losing its flexibility.
═════════════════════════════════════════════════════════════
⚪ Moving Particles
═════════════════════════════════════════════════════════════
What do they represent?
Real liquidity flow in the market — who's driving price right now.
● Number and Movement
- 6 particles covering most field lines
- Move sinusoidally along the arc:
t = (sin(phase_val) + 1) / 2
- High speed = High trading activity
- Clustering at a pole = That side's control
● Color Gradient
From green (at positive pole) to red (at negative)
Shows "energy transformation":
- Green particle = Pure buying energy
- Orange particle = Conflict zone
- Red particle = Pure selling energy
📌 How to Read Them?
- Moving left to right (🟢 → 🔴): Buy flow → Bullish push
- Moving right to left (🔴 → 🟢): Sell flow → Bearish push
- Clustered in middle: Balanced conflict — Wait for breakout
═════════════════════════════════════════════════════════════
🟠 Discharge Zone (Orange Glow — Center)
═════════════════════════════════════════════════════════════
What does it represent?
Point of stored energy accumulation not yet discharged — heart of the early warning system.
● Glow Stages
Initial Warning (discharge_prob > 0.3):
- Dim orange circle (70% transparency)
- Meaning: Watch, don't enter yet
High Tension (discharge_prob ≥ 0.7):
- Stronger glow + "⚠️ HIGH TENSION" text
- Meaning: Prepare — Set pending orders
Imminent Discharge (discharge_prob ≥ 0.9):
- Bright glow + "⚡ DISCHARGE IMMINENT" text
- Meaning: Enter with direction (after candle confirmation)
● Layered Glow Effect (Glow Layering)
3 concentric circles with increasing transparency:
- Inner: 20%
- Middle: 35%
- Outer: 50%
Result: Realistic aura resembling actual electrical discharge.
📌 Why in the Center?
Because discharge always starts from the relative balance zone — where opposing pressures meet.
═════════════════════════════════════════════════════════════
📊 Voltage Meter (Bottom of Scene)
═════════════════════════════════════════════════════════════
What does it represent?
Simplified numeric indicator of voltage difference — for those who prefer numerical reading.
● Components
- Gray bar: Full range (−100% to +100%)
- Green fill: Positive voltage (extends right)
- Red fill: Negative voltage (extends left)
- Lightning symbol (⚡): Above center — reminder it's an "electrical gauge"
- Text value: Like "+23.4%" — in direction color
● Voltage Reading Interpretation
+50% to +100%:
Overwhelming buying dominance — Beware of saturation, may precede correction
+20% to +50%:
Strong buying dominance — Suitable for buying with trend
+5% to +20%:
Slight bullish bias — Wait for additional confirmation
−5% to +5%:
Balance/Neutral — Avoid entry or wait for breakout
−5% to −20%:
Slight bearish bias — Wait for confirmation
−20% to −50%:
Strong selling dominance — Suitable for selling with trend
−50% to −100%:
Overwhelming selling dominance — Beware of saturation, may precede bounce
═════════════════════════════════════════════════════════════
📈 Field Strength Indicator (Top of Scene)
═════════════════════════════════════════════════════════════
What it displays: "Field: XX.X%"
Meaning: Strength of conflict between buyers and sellers.
● Reading Interpretation
0–5%:
- Appearance: Nearly straight lines, transparent
- Meaning: Complete control by one side
- Strategy: Trend Following
5–15%:
- Appearance: Slight curvature
- Meaning: Clear direction with light resistance
- Strategy: Enter with trend
15–25%:
- Appearance: Medium curvature, clear lines
- Meaning: Balanced conflict
- Strategy: Range trading or waiting
25–35%:
- Appearance: High curvature, clear density
- Meaning: Strong conflict, high uncertainty
- Strategy: Volatility trading or prepare for discharge
35%+:
- Appearance: Very high lines, strong glow
- Meaning: Peak tension
- Strategy: Best discharge opportunities
📌 Golden Relationship:
Highest discharge probability when:
Field Strength (25–35%) + Voltage (±30–50%) + High Volume
← This is the "red zone" to monitor carefully.
█ Comprehensive Visual Reading
To read market condition at a glance, follow this sequence:
Step 1: Which sphere is larger?
- 🟢 Green larger ← Dominant buying pressure
- 🔴 Red larger ← Dominant selling pressure
- Equal ← Balance/Conflict
Step 2: Which sphere is bright?
- 🟢 Green bright ← Current bullish direction
- 🔴 Red bright ← Current bearish direction
- Both dim ← Neutral/No clear direction
Step 3: Is there orange glow?
- None ← Discharge probability <30%
- 🟠 Dim glow ← Discharge probability 30–70%
- 🟠 Strong glow with text ← Discharge probability >70%
Step 4: What's the voltage meter reading?
- Strong positive ← Confirms buying dominance
- Strong negative ← Confirms selling dominance
- Near zero ← No clear direction
█ Practical Visual Reading Examples
Example 1: Ideal Buy Opportunity ⚡🟢
- Green sphere: Large and bright with inner pulse
- Red sphere: Small and dim
- Orange glow: Strong with "DISCHARGE IMMINENT" text
- Voltage meter: +45%
- Field strength: 28%
Interpretation: Strong accumulated buying pressure, bullish explosion imminent
Example 2: Ideal Sell Opportunity ⚡🔴
- Green sphere: Small and dim
- Red sphere: Large and bright with inner pulse
- Orange glow: Strong with "DISCHARGE IMMINENT" text
- Voltage meter: −52%
- Field strength: 31%
Interpretation: Strong accumulated selling pressure, bearish explosion imminent
Example 3: Balance/Wait ⚖️
- Both spheres: Approximately equal in size
- Lighting: Both dim
- Orange glow: Strong
- Voltage meter: +3%
- Field strength: 24%
Interpretation: Strong conflict without clear winner, wait for breakout
Example 4: Clear Uptrend (No Discharge) 📈
- Green sphere: Large and bright
- Red sphere: Very small and dim
- Orange glow: None
- Voltage meter: +68%
- Field strength: 8%
Interpretation: Clear buying control, limited conflict, suitable for following bullish trend
Example 5: Potential Buying Saturation ⚠️
- Green sphere: Very large and bright
- Red sphere: Very small
- Orange glow: Dim
- Voltage meter: +88%
- Field strength: 4%
Interpretation: Absolute buying dominance, may precede bearish correction
█ Trading Signals
⚡ DISCHARGE IMMINENT
Appearance Conditions:
- discharge_prob ≥ 0.9
- All enabled filters passed
- Confirmed (after candle close)
Interpretation:
- Very large energy accumulation
- Pressure reached critical level
- Price explosion expected within 1–3 candles
How to Trade:
1. Determine voltage direction:
• Positive = Expect rise
• Negative = Expect fall
2. Wait for confirmation candle:
• For rise: Bullish candle closing above its open
• For fall: Bearish candle closing below its open
3. Entry: With next candle's open
4. Stop Loss: Behind last local low/high
5. Target: Risk/Reward ratio of at least 1:2
✅ Pro Tips:
- Best results when combined with support/resistance levels
- Avoid entry if voltage is near zero (±5%)
- Increase position size when field strength > 30%
⚠️ HIGH TENSION
Appearance Conditions:
- 0.7 ≤ discharge_prob < 0.9
Interpretation:
- Market in energy accumulation state
- Likely strong move soon, but not immediate
- Accumulation may continue or discharge may occur
How to Benefit:
- Prepare: Set pending orders at potential breakouts
- Monitor: Watch following candles for momentum candle
- Select: Don't enter every signal — choose those aligned with overall trend
█ Trading Strategies
📈 Strategy 1: Discharge Trading (Basic)
Principle: Enter at "DISCHARGE IMMINENT" in voltage direction
Steps:
1. Wait for "⚡ DISCHARGE IMMINENT"
2. Check voltage direction (+/−)
3. Wait for confirmation candle in voltage direction
4. Enter with next candle's open
5. Stop loss behind last low/high
6. Target: 1:2 or 1:3 ratio
Very high success rate when following confirmation conditions.
📈 Strategy 2: Dominance Following
Principle: Trade with dominant pole (largest and brightest sphere)
Steps:
1. Identify dominant pole (largest and brightest)
2. Trade in its direction
3. Beware when sizes converge (conflict)
Suitable for higher timeframes (H1+).
📈 Strategy 3: Reversal Hunting
Principle: Counter-trend entry under certain conditions
Conditions:
- High field strength (>30%)
- Extreme voltage (>±40%)
- Divergence with price (e.g., new price high with declining voltage)
⚠️ High risk — Use small position size.
📈 Strategy 4: Integration with Technical Analysis
Strong Confirmation Examples:
- Resistance breakout + Bullish discharge = Excellent buy signal
- Support break + Bearish discharge = Excellent sell signal
- Head & Shoulders pattern + Increasing negative voltage = Pattern confirmation
- RSI divergence + High field strength = Potential reversal
█ Ready Alerts
Bullish Discharge
- Condition: discharge_prob ≥ 0.9 + Positive voltage + All filters
- Message: "⚡ Bullish discharge"
- Use: High probability buy opportunity
Bearish Discharge
- Condition: discharge_prob ≥ 0.9 + Negative voltage + All filters
- Message: "⚡ Bearish discharge"
- Use: High probability sell opportunity
✅ Tip: Use these alerts with "Once Per Bar" setting to avoid repetition.
█ Data Window Outputs
Bias
- Values: −1 / 0 / +1
- Interpretation: −1 = Bearish, 0 = Neutral, +1 = Bullish
- Use: For integration in automated strategies
Discharge %
- Range: 0–100%
- Interpretation: Discharge probability
- Use: Monitor tension progression (e.g., from 40% to 85% in 5 candles)
Field Strength
- Range: 0–100%
- Interpretation: Conflict intensity
- Use: Identify "opportunity window" (25–35% ideal for discharge)
Voltage
- Range: −100% to +100%
- Interpretation: Balance of power
- Use: Monitor extremes (potential buying/selling saturation)
█ Optimal Settings by Trading Style
Scalping
- Timeframe: 1M–5M
- Lookback: 10–15
- Threshold: 0.5–0.6
- Sensitivity: 1.2–1.5
- Filters: Volume + Volatility
Day Trading
- Timeframe: 15M–1H
- Lookback: 20
- Threshold: 0.7
- Sensitivity: 1.0
- Filters: Volume + Volatility
Swing Trading
- Timeframe: 4H–D1
- Lookback: 30–50
- Threshold: 0.8
- Sensitivity: 0.8
- Filters: Volatility + Trend
Position Trading
- Timeframe: D1–W1
- Lookback: 50–100
- Threshold: 0.85–0.95
- Sensitivity: 0.5–0.8
- Filters: All filters
█ Tips for Optimal Use
1. Start with Default Settings
Try it first as is, then adjust to your style.
2. Watch for Element Alignment
Best signals when:
- Clear voltage (>│20%│)
- Moderate–high field strength (15–35%)
- High discharge probability (>70%)
3. Use Multiple Timeframes
- Higher timeframe: Determine overall trend
- Lower timeframe: Time entry
- Ensure signal alignment between frames
4. Integrate with Other Tools
- Support/Resistance levels
- Trend lines
- Candle patterns
- Volume indicators
5. Respect Risk Management
- Don't risk more than 1–2% of account
- Always use stop loss
- Don't enter every signal — choose the best
█ Important Warnings
⚠️ Not for Standalone Use
The indicator is an analytical support tool — don't use it isolated from technical or fundamental analysis.
⚠️ Doesn't Predict the Future
Calculations are based on historical data — Results are not guaranteed.
⚠️ Markets Differ
You may need to adjust settings for each market:
- Forex: Focus on Volume Filter
- Stocks: Add Trend Filter
- Crypto: Lower Threshold slightly (more volatile)
⚠️ News and Events
The indicator doesn't account for sudden news — Avoid trading before/during major news.
█ Unique Features
✅ First Application of Electromagnetism to Markets
Innovative mathematical model — Not just an ordinary indicator
✅ Predictive Detection of Price Explosions
Alerts before the move happens — Not after
✅ Multi-Layer Filtering
4 smart filters reduce false signals to minimum
✅ Smart Volatility Adaptation
Automatically adjusts sensitivity based on market conditions
✅ Animated 3D Visual Representation
Makes reading instant — Even for beginners
✅ High Flexibility
Works on all assets: Stocks, Forex, Crypto, Commodities
✅ Built-in Ready Alerts
No complex setup needed — Ready for immediate use
█ Conclusion: When Art Meets Science
Market Electromagnetic Field is not just an indicator — but a new analytical philosophy.
It's the bridge between:
- Physics precision in describing dynamic systems
- Market intelligence in generating trading opportunities
- Visual psychology in facilitating instant reading
The result: A tool that isn't read — but watched, felt, and sensed.
When you see the green sphere expanding, the glow intensifying, and particles rushing rightward — you're not seeing numbers, you're seeing market energy breathing.
⚠️ Disclaimer:
This indicator is for educational and analytical purposes only. It does not constitute financial, investment, or trading advice. Use it in conjunction with your own strategy and risk management. Neither TradingView nor the developer is liable for any financial decisions or losses.
المجال الكهرومغناطيسي للسوق - Market Electromagnetic Field
مؤشر تحليلي مبتكر يقدّم نموذجًا جديدًا كليًّا لفهم ديناميكيات السوق، مستوحى من قوانين الفيزياء الكهرومغناطيسية — لكنه ليس استعارة بلاغية، بل نظام رياضي متكامل.
على عكس المؤشرات التقليدية التي تُركّز على السعر أو الزخم، يُصوّر هذا المؤشر السوق كـنظام فيزيائي مغلق، حيث:
⚡ الشموع = شحنات كهربائية (موجبة عند الإغلاق الصاعد، سالبة عند الهابط)
⚡ المشتريون والبائعون = قطبان متعاكسان يتراكم فيهما الضغط
⚡ التوتر السوقي = فرق جهد بين القطبين
⚡ الاختراق السعري = تفريغ كهربائي بعد تراكم طاقة كافية
█ الفكرة الجوهرية
الأسواق لا تتحرك عشوائيًّا، بل تخضع لدورة فيزيائية واضحة:
تراكم → توتر → تفريغ → استقرار → تراكم جديد
عندما تتراكم الشحنات (من خلال شموع قوية بحجم مرتفع) وتتجاوز "السعة الكهربائية" عتبة معيّنة، يُصدر المؤشر تنبيه "⚡ DISCHARGE IMMINENT" — أي أن انفجارًا سعريًّا وشيكًا، مما يمنح المتداول فرصة الدخول قبل بدء الحركة.
█ الميزة التنافسية
- تنبؤ استباقي (ليس تأكيديًّا بعد الحدث)
- فلترة ذكية متعددة الطبقات تقلل الإشارات الكاذبة
- تمثيل بصري ثلاثي الأبعاد متحرك يجعل قراءة الحالة السعرية فورية وبديهية — دون حاجة لتحليل أرقام
█ الأساس النظري الفيزيائي
المؤشر لا يستخدم مصطلحات فيزيائية للزينة، بل يُطبّق القوانين الرياضية مع تعديلات سوقيّة دقيقة:
⚡ قانون كولوم (Coulomb's Law)
الفيزياء: F = k × (q₁ × q₂) / r²
السوق: شدة الحقل = 4 × norm_positive × norm_negative
تصل لذروتها عند التوازن (0.5 × 0.5 × 4 = 1.0)، وتنخفض عند الهيمنة — لأن الصراع يزداد عند التكافؤ.
⚡ قانون أوم (Ohm's Law)
الفيزياء: V = I × R
السوق: الجهد = norm_positive − norm_negative
يقيس ميزان القوى:
- +1 = هيمنة شرائية مطلقة
- −1 = هيمنة بيعية مطلقة
- 0 = توازن
⚡ السعة الكهربائية (Capacitance)
الفيزياء: C = Q / V
السوق: السعة = |الجهد| × شدة الحقل
تمثّل الطاقة المخزّنة القابلة للتفريغ — تزداد عند وجود تحيّز مع تفاعل عالي.
⚡ التفريغ الكهربائي (Discharge)
الفيزياء: يحدث عند تجاوز عتبة العزل
السوق: احتمال التفريغ = min(السعة / عتبة التفريغ, 1.0)
عندما ≥ 0.9: "⚡ DISCHARGE IMMINENT"
📌 ملاحظة جوهرية:
أقصى سعة لا تحدث عند الهيمنة المطلقة (حيث شدة الحقل = 0)، ولا عند التوازن التام (حيث الجهد = 0)، بل عند انحياز متوسط (±30–50%) مع تفاعل عالي (شدة حقل > 25%) — أي في لحظات "الضغط قبل الاختراق".
█ آلية الحساب التفصيلية
⚡ المرحلة 1: قطبية الشمعة
polarity = (close − open) / (high − low)
- +1.0: شمعة صاعدة كاملة (ماروبوزو صاعد)
- −1.0: شمعة هابطة كاملة (ماروبوزو هابط)
- 0.0: دوجي (لا قرار)
- القيم الوسيطة: تمثّل نسبة جسم الشمعة إلى مداها — مما يقلّل تأثير الشموع ذات الظلال الطويلة
⚡ المرحلة 2: وزن الحجم
vol_weight = volume / SMA(volume, lookback)
شمعة بحجم 150% من المتوسط = شحنة أقوى بـ 1.5 مرة
⚡ المرحلة 3: معامل التكيف (Adaptive Factor)
adaptive_factor = ATR(lookback) / SMA(ATR, lookback × 2)
- في الأسواق المتقلبة: يزيد الحساسية
- في الأسواق الهادئة: يقلل الضوضاء
- يوصى دائمًا بتركه مفعّلًا
⚡ المرحلة 4–6: تراكم وتوحيد الشحنات
تُجمّع الشحنات على lookback شمعة، ثم تُوحّد النسب:
norm_positive = positive_charge / total_charge
norm_negative = negative_charge / total_charge
بحيث: norm_positive + norm_negative = 1 — لتسهيل المقارنة
⚡ المرحلة 7: حسابات الحقل
voltage = norm_positive − norm_negative
field_intensity = 4 × norm_positive × norm_negative × field_sensitivity
capacitance = |voltage| × field_intensity
discharge_prob = min(capacitance / discharge_threshold, 1.0)
█ الإعدادات
⚡ Electromagnetic Model
Lookback Period
- الافتراضي: 20
- النطاق: 5–100
- التوصيات:
- المضاربة: 10–15
- اليومي: 20
- السوينغ: 30–50
- الاستثمار: 50–100
Discharge Threshold
- الافتراضي: 0.7
- النطاق: 0.3–0.95
- التوصيات:
- سرعة + ضوضاء: 0.5–0.6
- توازن: 0.7
- دقة عالية: 0.8–0.95
Field Sensitivity
- الافتراضي: 1.0
- النطاق: 0.5–2.0
- التوصيات:
- تضخيم الصراع: 1.2–1.5
- طبيعي: 1.0
- تهدئة: 0.5–0.8
Adaptive Mode
- الافتراضي: مفعّل
- أبقِه دائمًا مفعّلًا
🔬 Dynamic Filters
يجب اجتياز جميع الفلاتر المفعّلة لظهور إشارة التفريغ.
Volume Filter
- الشرط: volume > SMA(volume) × vol_multiplier
- الوظيفة: يستبعد الشموع "الضعيفة" غير المدعومة بحجم
- التوصية: مفعّل (خاصة للأسهم والعملات)
Volatility Filter
- الشرط: STDEV > SMA(STDEV) × 0.5
- الوظيفة: يتجاهل فترات الركود الجانبي
- التوصية: مفعّل دائمًا
Trend Filter
- الشرط: توافق الجهد مع EMA سريع/بطيء
- الوظيفة: يقلل الإشارات المعاكسة للاتجاه العام
- التوصية: مفعّل للسوينغ/الاستثمار فقط
Volume Threshold
- الافتراضي: 1.2
- التوصيات:
- 1.0–1.2: حساسية عالية
- 1.5–2.0: حصرية للحجم العالي
🎨 Visual Settings
الإعدادات تُحسّن تجربة القراءة البصرية — لا تؤثر على الحسابات.
Scale Factor
- الافتراضي: 600
- كلما زاد: المشهد أكبر (200–1200)
Horizontal Shift
- الافتراضي: 180
- إزاحة أفقيّة لليسار — ليركّز على آخر شمعة
Pole Size
- الافتراضي: 60
- حجم الكرات الأساسية (30–120)
Field Lines
- الافتراضي: 8
- عدد خطوط الحقل (4–16) — 8 توازن مثالي
الألوان
- أخضر/أحمر/أزرق/برتقالي
- قابلة للتخصيص بالكامل
█ التمثيل البصري: لغة بصرية لتشخيص الحالة السعرية
✨ الفلسفة التصميمية
التمثيل ليس "زينة"، بل نموذج معرفي متكامل — كل عنصر يحمل معلومة، وتفاعل العناصر يروي قصة كاملة.
العقل يدرك التغيير في الحجم، اللون، والحركة أسرع بـ 60,000 مرة من قراءة الأرقام — لذا يمكنك "الإحساس" بالتغير قبل أن تُنهي العين المسح.
═════════════════════════════════════════════════════════════
🟢 القطب الموجب (الكرة الخضراء — يسار)
═════════════════════════════════════════════════════════════
ماذا يمثّل؟
تراكم ضغط الشراء النشط — ليس مجرد اتجاه صاعد، بل قوة طلب حقيقية مدعومة بحجم وتقلّب.
● الحجم المتغير
حجم = pole_size × (0.7 + norm_positive × 0.6)
- 70% من الحجم الأساسي = لا شحنة تُذكر
- 130% من الحجم الأساسي = هيمنة تامة
- كلما كبرت الكرة: زاد تفوّق المشترين، وارتفع احتمال الاستمرار الصعودي
تفسير الحجم:
- كرة كبيرة (>55%): ضغط شراء قوي — المشترون يسيطرون
- كرة متوسطة (45–55%): توازن نسبي مع ميل للشراء
- كرة صغيرة (<45%): ضعف ضغط الشراء — البائعون يسيطرون
● الإضاءة والشفافية
- شفافية 20% (عند Bias = +1): القطب نشط حالياً — الاتجاه صعودي
- شفافية 50% (عند Bias ≠ +1): القطب غير نشط — ليس الاتجاه السائد
الإضاءة = النشاط الحالي، بينما الحجم = التراكم التاريخي
● التوهج الداخلي النابض
كرة أصغر تنبض تلقائيًّا عند Bias = +1:
inner_pulse = 0.4 + 0.1 × sin(anim_time × 3)
يرمز إلى استمرارية تدفق أوامر الشراء — وليس هيمنة جامدة.
● الحلقات المدارية
حلقتان تدوران بسرعات واتجاهات مختلفة:
- الداخلية: 1.3× حجم الكرة — نطاق التأثير المباشر
- الخارجية: 1.6× حجم الكرة — نطاق التأثير الممتد
تمثّل "نطاق تأثير" المشترين:
- الدوران المستمر = استقرار وزخم
- التباطؤ = نفاد الزخم
● النسبة المئوية
تظهر تحت الكرة: norm_positive × 100
- >55% = هيمنة واضحة
- 45–55% = توازن
- <45% = ضعف
═════════════════════════════════════════════════════════════
🔴 القطب السالب (الكرة الحمراء — يمين)
═════════════════════════════════════════════════════════════
ماذا يمثّل؟
تراكم ضغط البيع النشط — سواء كان بيعًا تراكميًّا (التوزيع الذكي) أو بيعًا هستيريًّا (تصفية مراكز).
● الديناميكيات البصرية
نفس آلية الحجم والإضاءة والتوهج الداخلي — لكن باللون الأحمر.
الفرق الجوهري:
- الدوران معكوس (عكس اتجاه عقارب الساعة)
- يُميّز بصريًّا بين "تدفق الشراء" و"تدفق البيع"
- يسمح بقراءة الاتجاه بنظرة واحدة — حتى للمصابين بعَمَى الألوان
📌 ملخص قراءة القطبين:
🟢 كرة خضراء كبيرة + مضيئة = قوة شرائية نشطة
🔴 كرة حمراء كبيرة + مضيئة = قوة بيعية نشطة
🟢🔴 كرتان كبيرتان لكن خافتتان = تراكم طاقة (قبل التفريغ)
⚪ كرتان صغيرتان = ركود / سيولة منخفضة
═════════════════════════════════════════════════════════════
🔵 خطوط الحقل (الخطوط الزرقاء المنحنية)
═════════════════════════════════════════════════════════════
ماذا تمثّل؟
مسارات تدفق الطاقة بين القطبين — أي الساحة التي تُدار فيها المعركة السعرية.
● عدد الخطوط
4–16 خط (الافتراضي: 8)
كلما زاد العدد: زاد إحساس "كثافة التفاعل"
● ارتفاع القوس
arc_h = (i − half_lines) × 15 × field_intensity × 2
- شدة حقل عالية = خطوط شديدة الارتفاع (مثل موجة)
- شدة منخفضة = خطوط شبه مستقيمة
● الشفافية المتذبذبة
transp = 30 + phase × 40
حيث phase = sin(anim_time × 2 + i × 0.5) × 0.5 + 0.5
تخلق وهم "تيّار متدفّق" — وليس خطوطًا ثابتة
● الانحناء غير المتناظر
- الخطوط العلوية تنحني لأعلى
- الخطوط السفلية تنحني لأسفل
- يُضفي عمقًا ثلاثي الأبعاد ويُظهر اتجاه "الضغط"
⚡ تلميح احترافي:
عندما ترى الخطوط "تتقلّص" فجأة (تستقيم)، بينما الكرتان كبيرتان — فهذا مؤشر مبكر على قرب التفريغ، لأن التفاعل بدأ يفقد مرونته.
═════════════════════════════════════════════════════════════
⚪ الجزيئات المتحركة
═════════════════════════════════════════════════════════════
ماذا تمثّل؟
تدفق السيولة الحقيقية في السوق — أي من يدفع السعر الآن.
● العدد والحركة
- 6 جزيئات تغطي معظم خطوط الحقل
- تتحرك جيبيًّا على طول القوس:
t = (sin(phase_val) + 1) / 2
- سرعة عالية = نشاط تداول عالي
- تجمّع عند قطب = سيطرة هذا الطرف
● تدرج اللون
من أخضر (عند القطب الموجب) إلى أحمر (عند السالب)
يُظهر "تحوّل الطاقة":
- جزيء أخضر = طاقة شرائية نقية
- جزيء برتقالي = منطقة صراع
- جزيء أحمر = طاقة بيعية نقية
📌 كيف تقرأها؟
- تحركت من اليسار لليمين (🟢 → 🔴): تدفق شرائي → دفع صعودي
- تحركت من اليمين لليسار (🔴 → 🟢): تدفق بيعي → دفع هبوطي
- تجمّعت في المنتصف: صراع متكافئ — انتظر اختراقًا
═════════════════════════════════════════════════════════════
🟠 منطقة التفريغ (التوهج البرتقالي — المركز)
═════════════════════════════════════════════════════════════
ماذا تمثّل؟
نقطة تراكم الطاقة المخزّنة التي لم تُفرّغ بعد — قلب نظام الإنذار المبكر.
● مراحل التوهج
إنذار أولي (discharge_prob > 0.3):
- دائرة برتقالية خافتة (شفافية 70%)
- المعنى: راقب، لا تدخل بعد
توتر عالي (discharge_prob ≥ 0.7):
- توهج أقوى + نص "⚠️ HIGH TENSION"
- المعنى: استعد — ضع أوامر معلقة
تفريغ وشيك (discharge_prob ≥ 0.9):
- توهج ساطع + نص "⚡ DISCHARGE IMMINENT"
- المعنى: ادخل مع الاتجاه (بعد تأكيد شمعة)
● تأثير التوهج الطبقي (Glow Layering)
3 دوائر متحدة المركز بشفافية متزايدة:
- داخلي: 20%
- وسط: 35%
- خارجي: 50%
النتيجة: هالة (Aura) واقعية تشبه التفريغ الكهربائي الحقيقي.
📌 لماذا في المركز؟
لأن التفريغ يبدأ دائمًا من منطقة التوازن النسبي — حيث يلتقي الضغطان المتعاكسان.
═════════════════════════════════════════════════════════════
📊 مقياس الجهد (أسفل المشهد)
═════════════════════════════════════════════════════════════
ماذا يمثّل؟
مؤشر رقمي مبسّط لفرق الجهد — لمن يفضّل القراءة العددية.
● المكونات
- الشريط الرمادي: النطاق الكامل (−100% إلى +100%)
- التعبئة الخضراء: جهد موجب (تمتد لليمين)
- التعبئة الحمراء: جهد سالب (تمتد لليسار)
- رمز البرق (⚡): فوق المركز — تذكير بأنه "مقياس كهربائي"
- القيمة النصية: مثل "+23.4%" — بلون الاتجاه
● تفسير قراءات الجهد
+50% إلى +100%:
هيمنة شرائية ساحقة — احذر التشبع، قد يسبق تصحيح
+20% إلى +50%:
هيمنة شرائية قوية — مناسب للشراء مع الاتجاه
+5% إلى +20%:
ميل صعودي خفيف — انتظر تأكيدًا إضافيًّا
−5% إلى +5%:
توازن/حياد — تجنّب الدخول أو انتظر اختراقًا
−5% إلى −20%:
ميل هبوطي خفيف — انتظر تأكيدًا
−20% إلى −50%:
هيمنة بيعية قوية — مناسب للبيع مع الاتجاه
−50% إلى −100%:
هيمنة بيعية ساحقة — احذر التشبع، قد يسبق ارتداد
═════════════════════════════════════════════════════════════
📈 مؤشر شدة الحقل (أعلى المشهد)
═════════════════════════════════════════════════════════════
ما يعرضه: "Field: XX.X%"
الدلالة: قوة الصراع بين المشترين والبائعين.
● تفسير القراءات
0–5%:
- المظهر: خطوط مستقيمة تقريبًا، شفافة
- المعنى: سيطرة تامة لأحد الطرفين
- الاستراتيجية: تتبع الترند (Trend Following)
5–15%:
- المظهر: انحناء خفيف
- المعنى: اتجاه واضح مع مقاومة خفيفة
- الاستراتيجية: الدخول مع الاتجاه
15–25%:
- المظهر: انحناء متوسط، خطوط واضحة
- المعنى: صراع متوازن
- الاستراتيجية: تداول النطاق أو الانتظار
25–35%:
- المظهر: انحناء عالي، كثافة واضحة
- المعنى: صراع قوي، عدم يقين عالي
- الاستراتيجية: تداول التقلّب أو الاستعداد للتفريغ
35%+:
- المظهر: خطوط عالية جدًّا، توهج قوي
- المعنى: ذروة التوتر
- الاستراتيجية: أفضل فرص التفريغ
📌 العلاقة الذهبية:
أعلى احتمال تفريغ عندما:
شدة الحقل (25–35%) + جهد (±30–50%) + حجم مرتفع
← هذه هي "المنطقة الحمراء" التي يجب مراقبتها بدقة.
█ قراءة التمثيل البصري الشاملة
لقراءة حالة السوق بنظرة واحدة، اتبع هذا التسلسل:
الخطوة 1: أي كرة أكبر؟
- 🟢 الخضراء أكبر ← ضغط شراء مهيمن
- 🔴 الحمراء أكبر ← ضغط بيع مهيمن
- متساويتان ← توازن/صراع
الخطوة 2: أي كرة مضيئة؟
- 🟢 الخضراء مضيئة ← اتجاه صعودي حالي
- 🔴 الحمراء مضيئة ← اتجاه هبوطي حالي
- كلاهما خافت ← حياد/لا اتجاه واضح
الخطوة 3: هل يوجد توهج برتقالي؟
- لا يوجد ← احتمال تفريغ <30%
- 🟠 توهج خافت ← احتمال تفريغ 30–70%
- 🟠 توهج قوي مع نص ← احتمال تفريغ >70%
الخطوة 4: ما قراءة مقياس الجهد؟
- موجب قوي ← تأكيد الهيمنة الشرائية
- سالب قوي ← تأكيد الهيمنة البيعية
- قريب من الصفر ← لا اتجاه واضح
█ أمثلة عملية للقراءة البصرية
المثال 1: فرصة شراء مثالية ⚡🟢
- الكرة الخضراء: كبيرة ومضيئة مع نبض داخلي
- الكرة الحمراء: صغيرة وخافتة
- التوهج البرتقالي: قوي مع نص "DISCHARGE IMMINENT"
- مقياس الجهد: +45%
- شدة الحقل: 28%
التفسير: ضغط شراء قوي متراكم، انفجار صعودي وشيك
المثال 2: فرصة بيع مثالية ⚡🔴
- الكرة الخضراء: صغيرة وخافتة
- الكرة الحمراء: كبيرة ومضيئة مع نبض داخلي
- التوهج البرتقالي: قوي مع نص "DISCHARGE IMMINENT"
- مقياس الجهد: −52%
- شدة الحقل: 31%
التفسير: ضغط بيع قوي متراكم، انفجار هبوطي وشيك
المثال 3: توازن/انتظار ⚖️
- الكرتان: متساويتان تقريباً في الحجم
- الإضاءة: كلاهما خافت
- التوهج البرتقالي: قوي
- مقياس الجهد: +3%
- شدة الحقل: 24%
التفسير: صراع قوي بدون فائز واضح، انتظر اختراقًا
المثال 4: اتجاه صعودي واضح (لا تفريغ) 📈
- الكرة الخضراء: كبيرة ومضيئة
- الكرة الحمراء: صغيرة جداً وخافتة
- التوهج البرتقالي: لا يوجد
- مقياس الجهد: +68%
- شدة الحقل: 8%
التفسير: سيطرة شرائية واضحة، صراع محدود، مناسب لتتبع الترند الصعودي
المثال 5: تشبع شرائي محتمل ⚠️
- الكرة الخضراء: كبيرة جداً ومضيئة
- الكرة الحمراء: صغيرة جداً
- التوهج البرتقالي: خافت
- مقياس الجهد: +88%
- شدة الحقل: 4%
التفسير: هيمنة شرائية مطلقة، قد يسبق تصحيحاً هبوطياً
█ إشارات التداول
⚡ DISCHARGE IMMINENT (التفريغ الوشيك)
شروط الظهور:
- discharge_prob ≥ 0.9
- اجتياز جميع الفلاتر المفعّلة
- Confirmed (بعد إغلاق الشمعة)
التفسير:
- تراكم طاقة كبير جدًّا
- الضغط وصل لمستوى حرج
- انفجار سعري متوقع خلال 1–3 شموع
كيفية التداول:
1. حدد اتجاه الجهد:
• موجب = توقع صعود
• سالب = توقع هبوط
2. انتظر شمعة تأكيدية:
• للصعود: شمعة صاعدة تغلق فوق افتتاحها
• للهبوط: شمعة هابطة تغلق تحت افتتاحها
3. الدخول: مع افتتاح الشمعة التالية
4. وقف الخسارة: وراء آخر قاع/قمة محلية
5. الهدف: نسبة مخاطرة/عائد 1:2 على الأقل
✅ نصائح احترافية:
- أفضل النتائج عند دمجها مع مستويات الدعم/المقاومة
- تجنّب الدخول إذا كان الجهد قريبًا من الصفر (±5%)
- زِد حجم المركز عند شدة حقل > 30%
⚠️ HIGH TENSION (التوتر العالي)
شروط الظهور:
- 0.7 ≤ discharge_prob < 0.9
التفسير:
- السوق في حالة تراكم طاقة
- احتمال حركة قوية قريبة، لكن ليست فورية
- قد يستمر التراكم أو يحدث تفريغ
كيفية الاستفادة:
- الاستعداد: حضّر أوامر معلقة عند الاختراقات المحتملة
- المراقبة: راقب الشموع التالية بحثًا عن شمعة دافعة
- الانتقاء: لا تدخل كل إشارة — اختر تلك التي تتوافق مع الاتجاه العام
█ استراتيجيات التداول
📈 استراتيجية 1: تداول التفريغ (الأساسية)
المبدأ: الدخول عند "DISCHARGE IMMINENT" في اتجاه الجهد
الخطوات:
1. انتظر ظهور "⚡ DISCHARGE IMMINENT"
2. تحقق من اتجاه الجهد (+/−)
3. انتظر شمعة تأكيدية في اتجاه الجهد
4. ادخل مع افتتاح الشمعة التالية
5. وقف الخسارة وراء آخر قاع/قمة
6. الهدف: نسبة 1:2 أو 1:3
نسبة نجاح عالية جدًّا عند الالتزام بشروط التأكيد.
📈 استراتيجية 2: تتبع الهيمنة
المبدأ: التداول مع القطب المهيمن (الكرة الأكبر والأكثر إضاءة)
الخطوات:
1. حدد القطب المهيمن (الأكبر حجماً والأكثر إضاءة)
2. تداول في اتجاهه
3. احذر عند تقارب الأحجام (صراع)
مناسبة للإطارات الزمنية الأعلى (H1+).
📈 استراتيجية 3: صيد الانعكاس
المبدأ: الدخول عكس الاتجاه عند ظروف معينة
الشروط:
- شدة حقل عالية (>30%)
- جهد متطرف (>±40%)
- تباعد مع السعر (مثل: قمة سعرية جديدة مع تراجع الجهد)
⚠️ عالية المخاطرة — استخدم حجم مركز صغير.
📈 استراتيجية 4: الدمج مع التحليل الفني
أمثلة تأكيد قوي:
- اختراق مقاومة + تفريغ صعودي = إشارة شراء ممتازة
- كسر دعم + تفريغ هبوطي = إشارة بيع ممتازة
- نموذج Head & Shoulders + جهد سالب متزايد = تأكيد النموذج
- تباعد RSI + شدة حقل عالية = انعكاس محتمل
█ التنبيهات الجاهزة
Bullish Discharge
- الشرط: discharge_prob ≥ 0.9 + جهد موجب + جميع الفلاتر
- الرسالة: "⚡ Bullish discharge"
- الاستخدام: فرصة شراء عالية الاحتمالية
Bearish Discharge
- الشرط: discharge_prob ≥ 0.9 + جهد سالب + جميع الفلاتر
- الرسالة: "⚡ Bearish discharge"
- الاستخدام: فرصة بيع عالية الاحتمالية
✅ نصيحة: استخدم هذه التنبيهات مع إعداد "Once Per Bar" لتجنب التكرار.
█ المخرجات في نافذة البيانات
Bias
- القيم: −1 / 0 / +1
- التفسير: −1 = هبوطي، 0 = حياد، +1 = صعودي
- الاستخدام: لدمجها في استراتيجيات آلية
Discharge %
- النطاق: 0–100%
- التفسير: احتمال التفريغ
- الاستخدام: مراقبة تدرّج التوتر (مثال: من 40% إلى 85% في 5 شموع)
Field Strength
- النطاق: 0–100%
- التفسير: شدة الصراع
- الاستخدام: تحديد "نافذة الفرص" (25–35% مثالية للتفريغ)
Voltage
- النطاق: −100% إلى +100%
- التفسير: ميزان القوى
- الاستخدام: مراقبة التطرف (تشبع شرائي/بيعي محتمل)
█ الإعدادات المثلى حسب أسلوب التداول
المضاربة (Scalping)
- الإطار: 1M–5M
- Lookback: 10–15
- Threshold: 0.5–0.6
- Sensitivity: 1.2–1.5
- الفلاتر: Volume + Volatility
التداول اليومي (Day Trading)
- الإطار: 15M–1H
- Lookback: 20
- Threshold: 0.7
- Sensitivity: 1.0
- الفلاتر: Volume + Volatility
السوينغ (Swing Trading)
- الإطار: 4H–D1
- Lookback: 30–50
- Threshold: 0.8
- Sensitivity: 0.8
- الفلاتر: Volatility + Trend
الاستثمار (Position Trading)
- الإطار: D1–W1
- Lookback: 50–100
- Threshold: 0.85–0.95
- Sensitivity: 0.5–0.8
- الفلاتر: جميع الفلاتر
█ نصائح للاستخدام الأمثل
1. ابدأ بالإعدادات الافتراضية
جرّبه أولًا كما هو، ثم عدّل حسب أسلوبك.
2. راقب التوافق بين العناصر
أفضل الإشارات عندما:
- الجهد واضح (>│20%│)
- شدة الحقل معتدلة–عالية (15–35%)
- احتمال التفريغ مرتفع (>70%)
3. استخدم أطر زمنية متعددة
- الإطار الأعلى: تحديد الاتجاه العام
- الإطار الأدنى: توقيت الدخول
- تأكد من توافق الإشارات بين الأطر
4. دمج مع أدوات أخرى
- مستويات الدعم/المقاومة
- خطوط الاتجاه
- أنماط الشموع
- مؤشرات الحجم
5. احترم إدارة المخاطرة
- لا تخاطر بأكثر من 1–2% من الحساب
- استخدم دائمًا وقف الخسارة
- لا تدخل كل الإشارات — اختر الأفضل
█ تحذيرات مهمة
⚠️ ليس للاستخدام المنفرد
المؤشر أداة تحليل مساعِدة — لا تستخدمه بمعزل عن التحليل الفني أو الأساسي.
⚠️ لا يتنبأ بالمستقبل
الحسابات مبنية على البيانات التاريخية — النتائج ليست مضمونة.
⚠️ الأسواق تختلف
قد تحتاج لضبط الإعدادات لكل سوق:
- العملات: تركّز على Volume Filter
- الأسهم: أضف Trend Filter
- الكريبتو: خفّض Threshold قليلًا (أكثر تقلّبًا)
⚠️ الأخبار والأحداث
المؤشر لا يأخذ في الاعتبار الأخبار المفاجئة — تجنّب التداول قبل/أثناء الأخبار الرئيسية.
█ الميزات الفريدة
✅ أول تطبيق للكهرومغناطيسية على الأسواق
نموذج رياضي مبتكر — ليس مجرد مؤشر عادي
✅ كشف استباقي للانفجارات السعرية
يُنبّه قبل حدوث الحركة — وليس بعدها
✅ تصفية متعددة الطبقات
4 فلاتر ذكية تقلل الإشارات الكاذبة إلى الحد الأدنى
✅ تكيف ذكي مع التقلب
يضبط حساسيته تلقائيًّا حسب ظروف السوق
✅ تمثيل بصري ثلاثي الأبعاد متحرك
يجعل القراءة فورية — حتى للمبتدئين
✅ مرونة عالية
يعمل على جميع الأصول: أسهم، عملات، كريبتو، سلع
✅ تنبيهات مدمجة جاهزة
لا حاجة لإعدادات معقدة — جاهز للاستخدام الفوري
█ خاتمة: عندما يلتقي الفن بالعلم
Market Electromagnetic Field ليس مجرد مؤشر — بل فلسفة تحليلية جديدة.
هو الجسر بين:
- دقة الفيزياء في وصف الأنظمة الديناميكية
- ذكاء السوق في توليد فرص التداول
- علم النفس البصري في تسهيل القراءة الفورية
النتيجة: أداة لا تُقرأ — بل تُشاهد، تُشعر، وتُستشعر.
عندما ترى الكرة الخضراء تتوسع، والتوهج يصفرّ، والجزيئات تندفع لليمين — فأنت لا ترى أرقامًا، بل ترى طاقة السوق تتنفّس.
⚠️ إخلاء مسؤولية:
هذا المؤشر لأغراض تعليمية وتحليلية فقط. لا يُمثل نصيحة مالية أو استثمارية أو تداولية. استخدمه بالتزامن مع استراتيجيتك الخاصة وإدارة المخاطر. لا يتحمل TradingView ولا المطور مسؤولية أي قرارات مالية أو خسائر.
PineConnectorLibrary "PineConnector"
This library is a comprehensive alert webhook text generator for PineConnector. It contains every possible alert syntax variation from the documentation, along with some debugging functions.
To use it, just import the library (eg. "import ZenAndTheArtOfTrading/PineConnector/1 as pc") and use pc.buy(licenseID) to send an alert off to PineConnector - assuming all your webhooks etc are set up correctly.
View the PineConnector documentation for more information on how to send the commands you're looking to send (all of this library's function names match the documentation).
all()
Usage: pc.buy(pc_id, freq=pc.all())
Returns: "all"
once_per_bar()
Usage: pc.buy(pc_id, freq=pc.once_per_bar())
Returns: "once_per_bar"
once_per_bar_close()
Usage: pc.buy(pc_id, freq=pc.once_per_bar_close())
Returns: "once_per_bar_close"
na0(value)
Checks if given value is either 'na' or 0. Useful for streamlining scripts with float user setting inputs which default values to 0 since na is unavailable as a user input default.
Parameters:
value (float) : The value to check
Returns: True if the given value is 0 or na
getDecimals()
Calculates how many decimals are on the quote price of the current market.
Returns: The current decimal places on the market quote price
truncate(number, decimals)
Truncates the given number. Required params: mumber.
Parameters:
number (float) : Number to truncate
decimals (int) : Decimal places to cut down to
Returns: The input number, but as a string truncated to X decimals
getPipSize(multiplier)
Calculates the pip size of the current market.
Parameters:
multiplier (int) : The mintick point multiplier (1 by default, 10 for FX/Crypto/CFD but can be used to override when certain markets require)
Returns: The pip size for the current market
toWhole(number)
Converts pips into whole numbers. Required params: number.
Parameters:
number (float) : The pip number to convert into a whole number
Returns: The converted number
toPips(number)
Converts whole numbers back into pips. Required params: number.
Parameters:
number (float) : The whole number to convert into pips
Returns: The converted number
debug(txt, tooltip, displayLabel)
Prints to console and generates a debug label with the given text. Required params: txt.
Parameters:
txt (string) : Text to display
tooltip (string) : Tooltip to display (optional)
displayLabel (bool) : Turns on/off chart label (default: off)
Returns: Nothing
order(licenseID, command, symbol, parameters, accfilter, comment, secret, freq, debug)
Generates an alert string. Required params: licenseID, command.
Parameters:
licenseID (string) : Your PC license ID
command (string) : Command to send
symbol (string) : The symbol to trigger this order on
parameters (string) : Other optional parameters to include
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: An alert string with valid PC syntax based on supplied parameters
market_order(licenseID, buy, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a market entry alert with relevant syntax commands. Required params: licenseID, buy, risk.
Parameters:
licenseID (string) : Your PC license ID
buy (bool) : true=buy/long, false=sell/short
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A market order alert string with valid PC syntax based on supplied parameters
buy(licenseID, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a market buy alert with relevant syntax commands. Required params: licenseID, risk.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A market order alert string with valid PC syntax based on supplied parameters
sell(licenseID, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a market sell alert with relevant syntax commands. Required params: licenseID, risk.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A market order alert string with valid PC syntax based on supplied parameters
closeall(licenseID, comment, secret, freq, debug)
Closes all open trades at market regardless of symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closealleaoff(licenseID, comment, secret, freq, debug)
Closes all open trades at market regardless of symbol, and turns the EA off. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closelong(licenseID, symbol, comment, secret, freq, debug)
Closes all long trades at market for the given symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closeshort(licenseID, symbol, comment, secret, freq, debug)
Closes all open short trades at market for the given symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closelongshort(licenseID, symbol, comment, secret, freq, debug)
Closes all open trades at market for the given symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closelongbuy(licenseID, risk, symbol, comment, secret, freq, debug)
Close all long positions and open a new long at market for the given symbol with given risk/contracts. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : Risk or contracts (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closeshortsell(licenseID, risk, symbol, comment, secret, freq, debug)
Close all short positions and open a new short at market for the given symbol with given risk/contracts. Required params: licenseID, risk.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : Risk or contracts (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
newsltplong(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any open long trades on the given symbol with the given values. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
newsltpshort(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any open short trades on the given symbol with the given values. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closelongpct(licenseID, symbol, comment, secret, freq, debug)
Close a percentage of open long positions (according to EA settings). Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closeshortpct(licenseID, symbol, comment, secret, freq, debug)
Close a percentage of open short positions (according to EA settings). Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closelongvol(licenseID, risk, symbol, comment, secret, freq, debug)
Close all open long contracts on the current symbol until the given risk value is remaining. Required params: licenseID, risk.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : The quantity to leave remaining
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
closeshortvol(licenseID, risk, symbol, comment, secret, freq, debug)
Close all open short contracts on the current symbol until the given risk value is remaining. Required params: licenseID, risk.
Parameters:
licenseID (string) : Your PC license ID
risk (float) : The quantity to leave remaining
symbol (string) : Symbol to act on (defaults to current symbol)
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
limit_order(licenseID, buy, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a limit order alert with relevant syntax commands. Required params: licenseID, buy, price, risk.
Parameters:
licenseID (string) : Your PC license ID
buy (bool) : true=buy/long, false=sell/short
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A limit order alert string with valid PC syntax based on supplied parameters
buylimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a buylimit order alert with relevant syntax commands. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A limit order alert string with valid PC syntax based on supplied parameters
selllimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a selllimit order alert with relevant syntax commands. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A limit order alert string with valid PC syntax based on supplied parameters
stop_order(licenseID, buy, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a stop order alert with relevant syntax commands. Required params: licenseID, buy, price, risk.
Parameters:
licenseID (string) : Your PC license ID
buy (bool) : true=buy/long, false=sell/short
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
buystop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a buystop order alert with relevant syntax commands. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
sellstop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Generates a sellstop order alert with relevant syntax commands. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancel_neworder(licenseID, order, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Cancel + place new order template function.
Parameters:
licenseID (string) : Your PC license ID
order (string) : Cancel order type
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancellongbuystop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Cancels all long orders with the specified symbol and places a new buystop order. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancellongbuylimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Cancels all long orders with the specified symbol and places a new buylimit order. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancelshortsellstop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Cancels all short orders with the specified symbol and places a sellstop order. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancelshortselllimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
Cancels all short orders with the specified symbol and places a selllimit order. Required params: licenseID, price, risk.
Parameters:
licenseID (string) : Your PC license ID
price (float) : Price or pips to set limit order (according to EA settings)
risk (float) : Risk quantity (according to EA settings)
sl (float) : Stop loss distance in pips or price
tp (float) : Take profit distance in pips or price
betrigger (float) : Breakeven will be activated after the position gains this number of pips
beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
traildist (float) : Distance of the trailing stop-loss from current price
trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
atrperiod (int) : ATR averaging period
atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
symbol (string) : The symbol to trigger this order on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment (maximum 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A stop order alert string with valid PC syntax based on supplied parameters
cancellong(licenseID, symbol, accfilter, comment, secret, freq, debug)
Cancels all pending long orders with the specified symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A cancel long alert command
cancelshort(licenseID, symbol, accfilter, comment, secret, freq, debug)
Cancels all pending short orders with the specified symbol. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: A cancel short alert command
newsltpbuystop(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any pending buy stop orders on the given symbol. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
newsltpbuylimit(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any pending buy limit orders on the given symbol. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
newsltpsellstop(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any pending sell stop orders on the given symbol. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
newsltpselllimit(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
Updates the stop loss and/or take profit of any pending sell limit orders on the given symbol. Required params: licenseID, sl and/or tp.
Parameters:
licenseID (string) : Your PC license ID
sl (float) : Stop loss pips or price (according to EA settings)
tp (float) : Take profit pips or price (according to EA settings)
symbol (string) : Symbol to act on (defaults to current symbol)
accfilter (float) : Optional minimum account balance filter
comment (string) : Optional comment to include (max 20 characters)
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
eaoff(licenseID, secret, freq, debug)
Turns the EA off. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
eaon(licenseID, secret, freq, debug)
Turns the EA on. Required params: licenseID.
Parameters:
licenseID (string) : Your PC license ID
secret (string) : Optional secret key (must be enabled in dashboard)
freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
debug (bool) : Turns on/off debug label
Returns: The required alert syntax as a string
EMA Dynamic Crossover Detector with Real-Time Signal TableDescriptionWhat This Indicator Does:This indicator monitors all possible crossovers between four key exponential moving averages (20, 50, 100, and 200 periods) and displays them both visually on the chart and in an organized data table. Unlike standard EMA indicators that only plot the lines, this tool actively detects every crossover event, marks the exact crossover point with a circle, records the precise price level, and maintains a running log of all crossovers during the trading session. It's designed for traders who want comprehensive EMA crossover analysis without manually watching multiple moving average pairs.Key Features:
Four Essential EMAs: Plots 20, 50, 100, and 200-period exponential moving averages with color-coded thin lines for clean chart presentation
Complete Crossover Detection: Monitors all 6 possible EMA pair combinations (20×50, 20×100, 20×200, 50×100, 50×200, 100×200) in both directions
Precise Price Marking: Places colored circles at the exact average price where crossovers occur (not just at candle close)
Real-Time Signal Table: Displays up to 10 most recent crossovers with timestamp, direction, exact price, and signal type
Session Filtering: Only records crossovers during active trading hours (10:00-18:00 Istanbul time) to avoid noise from low-liquidity periods
Automatic Daily Reset: Clears the signal table at the start of each new trading day for fresh analysis
Built-In Alerts: Two alert conditions (bullish and bearish crossovers) that can be configured to send notifications
How It Works:The indicator calculates four exponential moving averages using the standard EMA formula, then continuously monitors for crossover events using Pine Script's ta.crossover() and ta.crossunder() functions:Bullish Crossovers (Green ▲):
When a faster EMA crosses above a slower EMA, indicating potential upward momentum:
20 crosses above 50, 100, or 200
50 crosses above 100 or 200
100 crosses above 200 (Golden Cross when it's the 50×200)
Bearish Crossovers (Red ▼):
When a faster EMA crosses below a slower EMA, indicating potential downward momentum:
20 crosses below 50, 100, or 200
50 crosses below 100 or 200
100 crosses below 200 (Death Cross when it's the 50×200)
Price Calculation:
Instead of marking crossovers at the candle's close price (which might not be where the actual cross occurred), the indicator calculates the average price between the two crossing EMAs, providing a more accurate representation of the crossover point.Signal Table Structure:The table in the top-right corner displays four columns:
Saat (Time): Exact time of crossover in HH:MM format
Yön (Direction): Arrow indicator (▲ green for bullish, ▼ red for bearish)
Fiyat (Price): Calculated average price at the crossover point
Durum (Status): Signal classification ("ALIŞ" for buy signals, "SATIŞ" for sell signals) with color-coded background
The table shows up to 10 most recent crossovers, automatically updating as new signals appear. If no crossovers have occurred during the session within the time filter, it displays "Henüz kesişim yok" (No crossovers yet).EMA Color Coding:
EMA 20 (Aqua/Turquoise): Fastest-reacting, most sensitive to recent price changes
EMA 50 (Green): Short-term trend indicator
EMA 100 (Yellow): Medium-term trend indicator
EMA 200 (Red): Long-term trend baseline, key support/resistance level
How to Use:For Day Traders:
Monitor 20×50 crossovers for quick entry/exit signals within the day
Use the time filter (10:00-18:00) to focus on high-volume trading hours
Check the signal table throughout the session to track momentum shifts
Look for confirmation: if 20 crosses above 50 and price is above EMA 200, bullish bias is stronger
For Swing Traders:
Focus on 50×200 crossovers (Golden Cross/Death Cross) for major trend changes
Use higher timeframes (4H, Daily) for more reliable signals
Wait for price to close above/below the crossover point before entering
Combine with support/resistance levels for better entry timing
For Position Traders:
Monitor 100×200 crossovers on daily/weekly charts for long-term trend changes
Use as confirmation of major market shifts
Don't react to every crossover—wait for sustained movement after the cross
Consider multiple timeframe analysis (if crossovers align on weekly and daily, signal is stronger)
Understanding EMA Hierarchies:The indicator becomes most powerful when you understand EMA relationships:Bullish Hierarchy (Strongest to Weakest):
All EMAs ascending (20 > 50 > 100 > 200): Strong uptrend
20 crosses above 50 while both are above 200: Pullback ending in uptrend
50 crosses above 200 while 20/50 below: Early trend reversal signal
Bearish Hierarchy (Strongest to Weakest):
All EMAs descending (20 < 50 < 100 < 200): Strong downtrend
20 crosses below 50 while both are below 200: Rally ending in downtrend
50 crosses below 200 while 20/50 above: Early trend reversal signal
Trading Strategy Examples:Pullback Entry Strategy:
Identify major trend using EMA 200 (price above = uptrend, below = downtrend)
Wait for pullback (20 crosses below 50 in uptrend, or above 50 in downtrend)
Enter when 20 re-crosses 50 in the trend direction
Place stop below/above the recent swing point
Exit when 20 crosses 50 against the trend again
Golden Cross/Death Cross Strategy:
Wait for 50×200 crossover (appears in the signal table)
Verify: Check if crossover occurs with increasing volume
Entry: Enter in the direction of the cross after a pullback
Stop: Place stop below/above the 200 EMA
Target: Swing high/low or when opposite crossover occurs
Multi-Crossover Confirmation:
Watch for multiple crossovers in the same direction within a short period
Example: 20×50 crossover followed by 20×100 = strengthening momentum
Enter after the second confirmation crossover
More crossovers = stronger signal but also means you're entering later
Time Filter Benefits:The 10:00-18:00 Istanbul time filter prevents recording crossovers during:
Pre-market volatility and gaps
Low-volume overnight sessions (for 24-hour markets)
After-hours erratic movements
Rollover LTEThis indicator shows where price needs to be and when in order to cause the 20-sma and 50-sma moving averages to change directions. A change in direction requires the slope of a moving average to change from negative to positive or from positive to negative. When a moving average changes direction, it can be said that it has “rolled over” or “rolled up,” with the latter only applying if slope went from negative to positive.
Theory:
In order to solve for the price of the current bar that will cause the moving average to roll up, the slope from the previous bar’s average to the current bar’s average must be set equal to zero which is to say that the averages must be the same.
For the 20-sma, the equation simply stated in words is as follows:
Current MA as a function of current price and previous 19 values = previous MA which is fixed based on previous 20 values
The denominators which are both 20 cancel and the previous 19 values cancel. What’s left is current price on the left side and the value from 20 bars ago on the right.
Current price = value from 20 bars ago
and since the equation was set up for solving for the price of the current bar that will cause the MA to roll over
Rollover price = value from 20 bars ago
This makes plotting rollover price, both current and forecasted, fairly simple, as it’s merely the closing price plotted with an offset to the right the same distance as the moving average length.
Application:
The 20-sma and 50-sma rollover prices are plotted because they are considered to be the two most important moving averages for rollover analysis. Moving average lengths can be modified in the indicator settings. The 20-sma and 20-sma rollover price are both plotted in white and the 50-sma and 50-sma rollover price are both plotted in blue. There are two rollover prices because the 20-sma rollover price is the price that will cause the 20-sma to roll over and the 50-sma rollover price is the price that will cause the 50-sma to roll over. The one that's vertically furthest away from the current price is the one that will cause both to rollover, as should become clearer upon reading the explanation below.
The distance between the current price and the 20-sma rollover price is referred to as the “rollover strength” of the price relative to the 20-sma. A large disparity between the current price and the rollover price suggests bearishness (negative rollover strength) if the rollover price is overhead because price would need to travel all that distance in order to cause the moving average to roll up. If the rollover price and price are converging, as is often the case, a change in moving average and price direction becomes more plausible. The rollover strengths of the 20-sma and 50-sma are added together to calculate the Rollover Strength and if a negative number is the result then the background color of the plot cloud turns red. If the result is positive, it turns green. Rollover Strength is plotted below price as a separate indicator in this publication for reference only and it's not part of this indicator. It does not look much different from momentum indicators. The code is below if anybody wants to try to use it. The important thing is that the distances between the rollover prices and the price action are kept in mind as having shrinking, growing, or neutral bearish and bullish effects on current and forecasted price direction. Trades should not be entered based on cloud colorization changes alone.
If you are about to crash into a wall of the 20-sma rollover price, as is indicated on the chart by the green arrow, you might consider going long so long as the rollover strength, both current and forecasted, of the 50-sma isn’t questionably bearish. This is subject to analysis and interpretation. There was a 20-sma rollover wall as indicated with yellow arrow, but the bearish rollover strength of the 50-sma was growing and forecasted to remain strong for a while at that time so a long entry would have not been suggested by both rollover prices. If you are about to crash into both the 20-sma and 50-sma rollover prices at the same time (not shown on this chart), that’s a good time to place a trade in anticipation of both slopes changing direction. You may, in the case of this chart, see that a 20-sma rollover wall precedes a 50-sma rollover convergence with price and anticipate a cascade which turned out to be the case with this recent NQ rally.
Price exiting the cloud entirely to either the upside or downside has strong implications. When exiting to the downside, the 20-sma and 50-sma have both rolled over and price is below both of them. The same is true for upside exits. Re-entering the cloud after a rally may indicate a reversal is near, especially if the forecasted rollover prices, particularly the 50-sma, agree.
This indicator should be used in conjunction with other technical analysis tools.
Additional Notes:
The original version of this script which will not be published was much heavier, cluttered, and is not as useful. This is the light version, hence the “LTE” suffix.
LTE stands for “long-term evolution” in telecommunications, not “light.”
Bar colorization (red, yellow, and green bars) was added using the MACD Hybrid BSH script which is another script I’ve published.
If you’re not sure what a bar is, it’s the same thing as a candle or a data point on a line chart. Every vertical line showing price action on the chart above is a bar and it is a bar chart.
sma = simple moving average
Rollover Strength Script:
// This source code is subject to the terms of the Mozilla Public License 2.0 at mozilla.org
// © Skipper86
//@version=5
indicator(title="Rollover Strength", shorttitle="Rollover Strength", overlay=false)
source = input.source(close)
length1 = input.int(20, "Length 1", minval=1)
length2 = input.int(50, "Length 2", minval=1)
RolloverPrice1 = source
RolloverPrice2 = source
RolloverStrength1 = source-RolloverPrice1
RolloverStrength2 = source-RolloverPrice2
RolloverStrength = RolloverStrength1 + RolloverStrength2
Color1 = color.rgb(155, 155, 155, 0)
Color2 = color.rgb(0, 0, 200, 0)
Color3 = color.rgb(0, 200, 0, 0)
plot(RolloverStrength, title="Rollover Strength", color=Color3)
hline(0, "Middle Band", color=Color1)
//End of Rollover Strength Script
Turtle Trader StrategyTurtle Trader Strategy :
Introduction :
This strategy is based on the well known « Turtle Trader Strategy », that has proven itself over the years. It sends long and short signals with pyramid orders of up to 5, meaning that the strategy can trigger up to 5 orders in the same direction. Good risk and money management.
It's important to note that the strategy combines 2 systems working together (S1 and S2). Let’s describe the specific features of this strategy.
1/ Position size :
Position size is very important for turtle traders to manage risk properly. This position sizing strategy adapts to market volatility and to account (gains and losses). It’s based on ATR (Average True Range) which can also be called « N ». Its length is per default 20.
ATR(20) = (previous_atr(20)*19 + actual_true_range)/20
The number of units to buy is :
Unit = 1% * account/(ATR(20)*dollar_per_point)
where account is the actual account value and dollar_per_point is the variation in dollar of the asset with a 1 point move.
Depending on your risk aversion, you can increase the percentage of your account, but turtle traders default to 1%. If you trade contracts, units must be rounded down by default.
There is also an additional rule to reduce the risk if the value of the account falls below the initial capital : in this case and only in this case, account in the unit formula must be replace by :
account = actual_account*actual_account/initial capital
2/ Open a position :
2 systems are working together :
System 1 : Entering a new 20 day breakout
System 2 : Entering a new 55 day breakout
A breakout is a new high or new low. If it’s a new high, we open long position and vice versa if it’s a new low we enter in short position.
We add an additional rule :
System 1 : Breakout is ignored if last long/short position was a winner
System 2 : All signals are taken
This additional rule allows the trader to be in the major trends if the system 1 signal has been skipped. If a signal for system 1 has been skipped, and next candle is also a new 20 day breakout, S1 doesn’t give a signal. We have to wait S2 signal or wait for a candle that doesn’t make a new breakout to reactivate S1.
3/ Pyramid orders :
Turtle Strategy allows us to add extra units to the position if the price moves in our favor. I've configured the strategy to allow up to 5 orders to be added in the same direction. So if the price varies from 0.5*ATR(20) , we add units with the position size formula. Note that the value of account will be replaced by "remaining_account", i.e. the cash remaining in our account after subtracting the value of open positions.
4/ Stop Loss :
We set a stop loss at 1.5*ATR(20) below the entry price for longs and above the entry price for shorts. If pyramid units are added, the stop is increased/decreased by 0.5*ATR(20). Note that if SL is configured for a loss of more than 10%, we set the SL to 10% for the first entry order to avoid big losses. This configuration does not work for pyramid orders as SL moves by 0.5*ATR(20).
5/ Exit signals :
System 1 :
Exit long on a 10 day low
Exit short on a 10 day high
System 2 :
Exit long on a 20 day low
Exit short on a 20 day high
6/ What types of orders are placed ?
To enter in a position, stop orders are placed meaning that we place orders that will be automatically triggered by the signal at the exact breakout price. Stop loss and exit signals are also stop orders. Pyramid orders are market orders which will be triggered at the opening of the next candle to avoid repainting.
PARAMETERS :
Risk % of capital : Percentage used in the position size formula. Default is 1%
ATR period : ATR length used to calculate ATR. Default is 20
Stop ATR : Parameters used to fix stop loss. Default is 1.5 meaning that stop loss will be set at : buy_price - 1.5*ATR(20) for long and buy_price + 1.5*ATR(20) for short. Turtle traders default is 2 but 1.5 is better for cryptocurrency as there is a huge volatility.
S1 Long : System 1 breakout length for long. Default is 20
S2 Long : System 2 breakout length for long. Default is 55
S1 Long Exit : System 1 breakout length to exit long. Default is 10
S2 Long Exit : System 2 breakout length to exit long. Default is 20
S1 Short : System 1 breakout length for short. Default is 15
S2 Short : System 2 breakout length for short. Default is 55
S1 Short Exit : System 1 breakout length to exit short. Default is 7
S2 Short Exit : System 2 breakout length to exit short. Default is 20
Initial capital : $1000
Fees : Interactive Broker fees apply to this strategy. They are set at 0.18% of the trade value.
Slippage : 3 ticks or $0.03 per trade. Corresponds to the latency time between the moment the signal is received and the moment the order is executed by the broker.
Pyramiding : Number of orders that can be passed in the same direction. Default is 5.
Important : Turtle traders don't trade crypto. For this specific asset type, I modify some parameters such as SL and Short S1 in order to maximize return while limiting drawdown. This strategy is the most optimal on BINANCE:BTCUSD in 1D timeframe with the parameters set per default. If you want to use this strategy for a different crypto please adapt parameters.
NOTE :
It's important to note that the first entry order (long or short) will be the largest. Subsequent pyramid orders will have fewer units than the first order. We've set a maximum SL for the first order of 10%, meaning that you won't lose more than 10% of the value of your first order. However, it is possible to lose more on your pyramid orders, as the SL is increased/decreased by 0.5*ATR(20), which does not secure a loss of more than 10% on your pyramid orders. The risk remains well managed because the value of these orders is less than the value of the first order. Remain vigilant to this small detail and adjust your risk according to your risk aversion.
Enjoy the strategy and don’t forget to take the trade :)






















