OPEN-SOURCE SCRIPT
ที่อัปเดต: Smart Range Detector

Smart Range Detector
What It Does
This indicator automatically detects and validates significant trading ranges using pivot point analysis combined with logarithmic fibonacci relationships. It operates by identifying specific pivot patterns (High-Low-High and Low-High-Low) that meet fibonacci validation criteria to filter out noise and highlight only the most reliable trading ranges. Each range is continuously monitored for potential mitigation (breakout) events.
Key Features
How To Use It
Settings Guide
Technical Details
This indicator works well on all timeframes and instruments, but performs best on 5-minute to daily charts. Perfect for swing traders, range traders, and breakout strategists.
What Makes It Different
Most range indicators simply draw boxes based on recent highs and lows. Smart Range Detector validates each potential range using proven fibonacci relationships to filter out noise. It then adds sophisticated volume analysis to help traders identify the most significant price levels within each range. The performance optimization features ensure smooth operation even on lower timeframes and extended history analysis.
What It Does
This indicator automatically detects and validates significant trading ranges using pivot point analysis combined with logarithmic fibonacci relationships. It operates by identifying specific pivot patterns (High-Low-High and Low-High-Low) that meet fibonacci validation criteria to filter out noise and highlight only the most reliable trading ranges. Each range is continuously monitored for potential mitigation (breakout) events.
Key Features
- Identifies both High-Low-High and Low-High-Low range patterns
- Validates each range using logarithmic fibonacci relationships (more accurate than linear fibs)
- Detects range mitigations (breakouts) and visually differentiates them
- Shows fibonacci levels within ranges (25%, 50%, 75%) for potential reversal points
- Visualizes extension levels beyond ranges for breakout targets
- Analyzes volume profile with customizable price divisions (default: 60)
- Displays Point of Control (POC) and Value Area for traded volume analysis
- Implements performance optimization with configurable range limits
- Includes user-adjustable safety checks to prevent Pine Script limitations
- Offers fully customizable colors, line widths, and transparency settings
How To Use It
- Identify Valid Ranges: The indicator automatically detects and highlights trading ranges that meet fibonacci validation criteria
- Monitor Fibonacci Levels: Watch for price reactions at internal fib levels (25%, 50%, 75%) for potential reversal opportunities
- Track Extension Targets: Use the extension lines as potential targets when price breaks out of a range
- Analyze Volume Structure: Enable the volume profile mode to see where most volume was traded within mitigated ranges
- Trade Range Boundaries: Look for reactions at range highs/lows combined with volume POC for higher probability entries
- Manage Performance: Adjust the maximum displayed ranges and history bars settings for optimal chart performance
Settings Guide
- Left/Right Bars Look Back: Controls how far back the indicator looks to identify pivot points (higher values find more ranges but may reduce sensitivity)
- Max History Bars: Limits how far back in history the indicator will analyze (stays within Pine Script's 10,000 bar limitation)
- Max Ranges to Display: Restricts the total number of ranges kept in memory for improved performance (1-50)
- Volume Profile: When enabled, shows volume distribution analysis for mitigated ranges
- Volume Profile Divisions: Controls the granularity of the volume analysis (higher values show more detail)
- Display Options: Toggle visibility of range lines, fibonacci levels, extension lines, and volume analysis elements
- Transparency & Color Settings: Fully customize the visual appearance of all indicator elements
- Line Width Settings: Adjust the thickness of lines for better visibility on different timeframes
Technical Details
- The indicator uses logarithmic fibonacci calculations for more accurate price relationships
- Volume profile analysis creates 60 price divisions by default (adjustable) for detailed volume distribution
- All timestamps are properly converted to work with Pine Script's bar limitations
- Safety checks prevent "array index out of bounds" errors that plague many complex indicators
- Time-based coordinates are used instead of bar indices to prevent "bar index too far" errors
This indicator works well on all timeframes and instruments, but performs best on 5-minute to daily charts. Perfect for swing traders, range traders, and breakout strategists.
What Makes It Different
Most range indicators simply draw boxes based on recent highs and lows. Smart Range Detector validates each potential range using proven fibonacci relationships to filter out noise. It then adds sophisticated volume analysis to help traders identify the most significant price levels within each range. The performance optimization features ensure smooth operation even on lower timeframes and extended history analysis.
เอกสารเผยแพร่
- Upgraded to V6- Fixed Problem with VP Mode
- Added Vwap Mode
เอกสารเผยแพร่
- Optimized Range Detection wont miss any range, wont over detect eitherเอกสารเผยแพร่
- Added an update to help trading range as they breakoutเอกสารเผยแพร่
- Adaptive Mitigation- Better Range tracking with VWAP/VP Modes
เอกสารเผยแพร่
- Fixed Issue where Ranges where covered with Multiple Boxes- Faster
เอกสารเผยแพร่
- Better Mitigation Methods- Custom Displays vs Mitigation Levels
เอกสารเผยแพร่
- Ability To Delete Unmitigated ranges after a Periodเอกสารเผยแพร่
- Added Signals for Range Retestเอกสารเผยแพร่
- Alert Frequency to Bar Closeเอกสารเผยแพร่
- Mitigated Range Extension Addedเอกสารเผยแพร่
- Cleaning to Avoid Double Boxingเอกสารเผยแพร่
- Allow Retest for All Ranges that are Mitigatedเอกสารเผยแพร่
- Major Speed Upgradeเอกสารเผยแพร่
- Hotfix (Issue where it don't work when new bars get created)เอกสารเผยแพร่
- A lot of Clean-up- A lot of Big O clean-ups and speed and performance improvement
เอกสารเผยแพร่
- Sweep Cleaningเอกสารเผยแพร่
- Volume Filteringเอกสารเผยแพร่
- Added Open / Wick Sweepเอกสารเผยแพร่
- Mean Reversal Addedเอกสารเผยแพร่
- Alot of Extras for Mean Reversion Traders- Added TPO Range Calculation
- Added POC Tests
เอกสารเผยแพร่
- Refactored Code for Speed- Optimized Zig Zag Logic
เอกสารเผยแพร่
- Small Volume Condition Fine Tuning เอกสารเผยแพร่
- Updated Modesสคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน
สคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน