PINE LIBRARY
已更新 MaidongOrderBlockRefiner

Library "MaidongOrderBlockRefiner"
Maidong Order Block Refiner is a Pine Script library designed to refine already-detected order blocks into tighter and more actionable trading zones.
This library does not detect market structure, identify order blocks, or draw zones by itself. Instead, it acts as a reusable refinement layer that accepts an externally confirmed order block origin and returns refined distal and proximal boundaries that can be used by drawing, alert, or setup modules.
Core features:
- Supports both `Demand` and `Supply` order blocks
- Supports `On` / `Off` refinement mode
- Supports `Defensive` and `Aggressive` refinement styles
- Uses ATR-aware width handling to compress oversized zones
- Returns distal and proximal coordinates ready for downstream drawing logic
This library is useful when:
- You already have your own structure or order block detection logic
- You want to compress raw order block ranges into cleaner execution zones
- You want to reuse the same refinement model across multiple indicators
OBRefiner(obType, obRefine, refineMethod, triggerCondition, index)
Parameters:
obType (string)
obRefine (string)
refineMethod (string)
triggerCondition (bool)
index (int)
Maidong Order Block Refiner is a Pine Script library designed to refine already-detected order blocks into tighter and more actionable trading zones.
This library does not detect market structure, identify order blocks, or draw zones by itself. Instead, it acts as a reusable refinement layer that accepts an externally confirmed order block origin and returns refined distal and proximal boundaries that can be used by drawing, alert, or setup modules.
Core features:
- Supports both `Demand` and `Supply` order blocks
- Supports `On` / `Off` refinement mode
- Supports `Defensive` and `Aggressive` refinement styles
- Uses ATR-aware width handling to compress oversized zones
- Returns distal and proximal coordinates ready for downstream drawing logic
This library is useful when:
- You already have your own structure or order block detection logic
- You want to compress raw order block ranges into cleaner execution zones
- You want to reuse the same refinement model across multiple indicators
OBRefiner(obType, obRefine, refineMethod, triggerCondition, index)
Parameters:
obType (string)
obRefine (string)
refineMethod (string)
triggerCondition (bool)
index (int)
版本注释
v2Fix: Too large total max_bars_back 310201 max 300000 allowed.
Pine脚本库
秉承TradingView的精神,作者已将此Pine代码作为开源库发布,以便我们社区的其他Pine程序员可以重用它。向作者致敬!您可以私下或在其他开源出版物中使用此库,但在出版物中重用此代码须遵守网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
Pine脚本库
秉承TradingView的精神,作者已将此Pine代码作为开源库发布,以便我们社区的其他Pine程序员可以重用它。向作者致敬!您可以私下或在其他开源出版物中使用此库,但在出版物中重用此代码须遵守网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。