PINE LIBRARY
已更新 BoxesLib

Library "BoxesLib"
isOverlappingBox(_boxes, _top, _bottom)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
isTooCloseBox(_boxes, _top, _bottom, zoneProximityPct)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
zoneProximityPct (float)
createBox(_boxes, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, zoneProximityPct, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
zoneProximityPct (float)
currentClose (float)
isConfirmed (bool)
manageBoxes(_boxes, _is_breakout, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_is_breakout (bool)
currentClose (float)
isConfirmed (bool)
isOverlappingBox(_boxes, _top, _bottom)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
isTooCloseBox(_boxes, _top, _bottom, zoneProximityPct)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
zoneProximityPct (float)
createBox(_boxes, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, zoneProximityPct, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
zoneProximityPct (float)
currentClose (float)
isConfirmed (bool)
manageBoxes(_boxes, _is_breakout, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_is_breakout (bool)
currentClose (float)
isConfirmed (bool)
版本注释
v2Added Confluence label to identify strong Support and Resistance
版本注释
v3Updated:
createBox(_boxes, _boxTexts, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, zoneProximityPct, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_boxTexts (array<string>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
zoneProximityPct (float)
currentClose (float)
isConfirmed (bool)
版本注释
v4Updated:
createBox(_boxes, _boxTexts, _isConfluence, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, zoneProximityPct, currentClose, isConfirmed)
Parameters:
_boxes (array<box>)
_boxTexts (array<string>)
_isConfluence (array<bool>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
zoneProximityPct (float)
currentClose (float)
isConfirmed (bool)
版本注释
v5Updated:
createBox(_boxes, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, zoneProximityPct, currentClose, isConfirmed, confluenceColor)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
zoneProximityPct (float)
currentClose (float)
isConfirmed (bool)
confluenceColor (color)
版本注释
v6Text color changed to Black
版本注释
v7Added:
isBoxConfluent(_testBox, _allBoxes)
Parameters:
_testBox (box)
_allBoxes (array<box>)
版本注释
v8Added:
getConfluenceBoxes(_boxes)
Parameters:
_boxes (array<box>)
版本注释
v9What it does (for your users):
Overlap check (isOverlappingBox): blocks new boxes if they geometrically overlap existing ones.
Proximity check (isTooCloseBox): blocks near-duplicates within zoneProximityPct.
Confluence detection (isBoxConfluent / getConfluenceBoxes): a box is confluent only if another box with different bounds strictly overlaps it (self is skipped).
Creation (createBox):
If no overlap and not too close → create normal box.
If overlap or too close → recolor the existing overlapping/near boxes to the confluence color; do not add a new box.
Enforces capacity and deletes broken boxes against direction.
Maintenance (manageBoxes): keeps boxes aligned to the latest bar and removes invalidated boxes.
版本注释
v10Updated:
createBox(_boxes, _top, _bottom, _leftBarIndex, _color, _txt, _is_breakout, numberLimit, currentClose, isConfirmed, confluenceColor)
Parameters:
_boxes (array<box>)
_top (float)
_bottom (float)
_leftBarIndex (int)
_color (color)
_txt (string)
_is_breakout (bool)
numberLimit (int)
currentClose (float)
isConfirmed (bool)
confluenceColor (color)
Removed:
isTooCloseBox(_boxes, _top, _bottom, zoneProximityPct)
版本注释
v11Removed:
isOverlappingBox(_boxes, _top, _bottom)
isBoxConfluent(_testBox, _allBoxes)
getConfluenceBoxes(_boxes)
版本注释
v12Pine脚本库
秉承TradingView的精神,作者已将此Pine代码作为开源库发布,以便我们社区的其他Pine程序员可以重用它。向作者致敬!您可以私下或在其他开源出版物中使用此库,但在出版物中重用此代码须遵守网站规则。
Sreenureddy
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
Pine脚本库
秉承TradingView的精神,作者已将此Pine代码作为开源库发布,以便我们社区的其他Pine程序员可以重用它。向作者致敬!您可以私下或在其他开源出版物中使用此库,但在出版物中重用此代码须遵守网站规则。
Sreenureddy
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。