PINE LIBRARY
HarmonicMapLib

Library "HarmonicMapLib"
Harmonic Pattern Library implementation utilising maps
method tostring(this)
convert Range value to string
Namespace types: Range
Parameters:
this (Range): Range value
Returns: converted string representation
method tostring(this)
convert array of Range value to string
Namespace types: array<Range>
Parameters:
this (array<Range>): array<Range> object
Returns: converted string representation
method tostring(this)
convert map of string to Range value to string
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map<string,Range> object
Returns: converted string representation
method tostring(this)
convert RatioMap to string
Namespace types: RatioMap
Parameters:
this (RatioMap): RatioMap object
Returns: converted string representation
method tostring(this)
convert array of RatioMap to string
Namespace types: array<RatioMap>
Parameters:
this (array<RatioMap>): array<RatioMap> object
Returns: converted string representation
method tostring(this)
convert map of string to RatioMap to string
Namespace types: map<string, RatioMap>
Parameters:
this (map<string, RatioMap>): map<string, RatioMap> object
Returns: converted string representation
method tostring(this)
convert map of string to bool to string
Namespace types: map<string, bool>
Parameters:
this (map<string, bool>): map<string, bool> object
Returns: converted string representation
method tostring(this)
convert PrzRange to string
Namespace types: PrzRange
Parameters:
this (PrzRange): PrzRange object
Returns: converted string representation
method tostring(this)
convert array of PrzRange to string
Namespace types: array<PrzRange>
Parameters:
this (array<PrzRange>): array<PrzRange> object
Returns: converted string representation
getHarmonicMap()
Creates the RatioMap for harmonic patterns
Returns: map<string, RatioMap> haronic ratio rules for all patterns
method evaluate(patternsMap, pattern, ratioRange, properties, ratioValue)
evaluates harmonic ratio range
Namespace types: map<string, bool>
Parameters:
patternsMap (map<string, bool>): parameter containing valid pattern names
pattern (string): Pattern type to be evaluated
ratioRange (Range): ratio range to be checked
properties (ScanProperties): Scan Properties
ratioValue (float)
Returns: void
method evaluate(przRange, pattern, ratioRange, priceRange, properties)
Evaluate PRZ ranges
Namespace types: map<string, Range>
Parameters:
przRange (map<string, Range>)
pattern (string): Pattern name
ratioRange (Range): Range of ratio for the pattern
priceRange (Range): Price range based on ratio
properties (ScanProperties): ScanProperties object
Returns: void
method scanRatio(currentPatterns, rules, properties, ratioName, ratioValue)
Scan for particular named ratio of harmonic pattern to filter valid patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): Current valid patterns map
rules (map<string, RatioMap>): map<string, RatioMap> Harmonic ratio rules
properties (ScanProperties): ScanProperties object
ratioName (string): Specific ratio name
ratioValue (float): ratio value to be checked
Returns: updated currentPatterns object
method scanPatterns(patterns, x, a, b, c, d, properties)
Scan for patterns based on X, A, B, C, D values
Namespace types: map<string, bool>
Parameters:
patterns (map<string, bool>): List of allowed patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
d (float): D coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: updated valid patterns map
method scanProjections(patterns, x, a, b, c, properties)
Scan for projections based on X, A, B, C values
Namespace types: map<string, bool>
Parameters:
patterns (map<string, bool>): List of allowed patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: updated valid projections map
method merge(this, other)
merge two ranges into one
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: combined range
method union(this, other)
union of two ranges into one
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: union range
method overlaps(this, other)
checks if two ranges intersect
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: true if intersects, false otherwise
method consolidate(this)
Consolidate ranges into PRZ
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map of Ranges
Returns: consolidated PRZ
method consolidateMany(this)
Consolidate ranges into multiple PRZ ranges
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map of Ranges
Returns: consolidated array of PRZ ranges
method getRange(currentPatterns, x, a, b, c, properties)
Get D range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: map of D ranges
method getPrzRange(currentPatterns, x, a, b, c, properties)
Get PRZ range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: PRZRange for the pattern
method getProjectionRanges(currentPatterns, x, a, b, c, properties)
Get projection range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: array of projection ranges
Range
Collection of range values
Fields:
values (array<float>): array of float values
RatioMap
ratio map for pattern
Fields:
ratioMap (map<string, Range>): map of string to Range (array of float)
ScanProperties
Pattern Scanning properties
Fields:
strictMode (series bool): strict scanning mode will check for overflows
logScale (series bool): scan ratios in log scale
errorMin (series float): min error threshold
errorMax (series float)
mintick (series float): minimum tick value of price
PrzRange
Potential reversal zone range
Fields:
patterns (array<string>): array of pattern names for the given XABCD combination
prz (Range): PRZ range
Harmonic Pattern Library implementation utilising maps
method tostring(this)
convert Range value to string
Namespace types: Range
Parameters:
this (Range): Range value
Returns: converted string representation
method tostring(this)
convert array of Range value to string
Namespace types: array<Range>
Parameters:
this (array<Range>): array<Range> object
Returns: converted string representation
method tostring(this)
convert map of string to Range value to string
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map<string,Range> object
Returns: converted string representation
method tostring(this)
convert RatioMap to string
Namespace types: RatioMap
Parameters:
this (RatioMap): RatioMap object
Returns: converted string representation
method tostring(this)
convert array of RatioMap to string
Namespace types: array<RatioMap>
Parameters:
this (array<RatioMap>): array<RatioMap> object
Returns: converted string representation
method tostring(this)
convert map of string to RatioMap to string
Namespace types: map<string, RatioMap>
Parameters:
this (map<string, RatioMap>): map<string, RatioMap> object
Returns: converted string representation
method tostring(this)
convert map of string to bool to string
Namespace types: map<string, bool>
Parameters:
this (map<string, bool>): map<string, bool> object
Returns: converted string representation
method tostring(this)
convert PrzRange to string
Namespace types: PrzRange
Parameters:
this (PrzRange): PrzRange object
Returns: converted string representation
method tostring(this)
convert array of PrzRange to string
Namespace types: array<PrzRange>
Parameters:
this (array<PrzRange>): array<PrzRange> object
Returns: converted string representation
getHarmonicMap()
Creates the RatioMap for harmonic patterns
Returns: map<string, RatioMap> haronic ratio rules for all patterns
method evaluate(patternsMap, pattern, ratioRange, properties, ratioValue)
evaluates harmonic ratio range
Namespace types: map<string, bool>
Parameters:
patternsMap (map<string, bool>): parameter containing valid pattern names
pattern (string): Pattern type to be evaluated
ratioRange (Range): ratio range to be checked
properties (ScanProperties): Scan Properties
ratioValue (float)
Returns: void
method evaluate(przRange, pattern, ratioRange, priceRange, properties)
Evaluate PRZ ranges
Namespace types: map<string, Range>
Parameters:
przRange (map<string, Range>)
pattern (string): Pattern name
ratioRange (Range): Range of ratio for the pattern
priceRange (Range): Price range based on ratio
properties (ScanProperties): ScanProperties object
Returns: void
method scanRatio(currentPatterns, rules, properties, ratioName, ratioValue)
Scan for particular named ratio of harmonic pattern to filter valid patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): Current valid patterns map
rules (map<string, RatioMap>): map<string, RatioMap> Harmonic ratio rules
properties (ScanProperties): ScanProperties object
ratioName (string): Specific ratio name
ratioValue (float): ratio value to be checked
Returns: updated currentPatterns object
method scanPatterns(patterns, x, a, b, c, d, properties)
Scan for patterns based on X, A, B, C, D values
Namespace types: map<string, bool>
Parameters:
patterns (map<string, bool>): List of allowed patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
d (float): D coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: updated valid patterns map
method scanProjections(patterns, x, a, b, c, properties)
Scan for projections based on X, A, B, C values
Namespace types: map<string, bool>
Parameters:
patterns (map<string, bool>): List of allowed patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: updated valid projections map
method merge(this, other)
merge two ranges into one
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: combined range
method union(this, other)
union of two ranges into one
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: union range
method overlaps(this, other)
checks if two ranges intersect
Namespace types: Range
Parameters:
this (Range): first range
other (Range): second range
Returns: true if intersects, false otherwise
method consolidate(this)
Consolidate ranges into PRZ
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map of Ranges
Returns: consolidated PRZ
method consolidateMany(this)
Consolidate ranges into multiple PRZ ranges
Namespace types: map<string, Range>
Parameters:
this (map<string, Range>): map of Ranges
Returns: consolidated array of PRZ ranges
method getRange(currentPatterns, x, a, b, c, properties)
Get D range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: map of D ranges
method getPrzRange(currentPatterns, x, a, b, c, properties)
Get PRZ range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: PRZRange for the pattern
method getProjectionRanges(currentPatterns, x, a, b, c, properties)
Get projection range based on X, A, B, C coordinates for the current patterns
Namespace types: map<string, bool>
Parameters:
currentPatterns (map<string, bool>): List of valid patterns
x (float): X coordinate
a (float): A coordinate
b (float): B coordinate
c (float): C coordinate
properties (ScanProperties): ScanProperties object. If na, default values are initialised
Returns: array of projection ranges
Range
Collection of range values
Fields:
values (array<float>): array of float values
RatioMap
ratio map for pattern
Fields:
ratioMap (map<string, Range>): map of string to Range (array of float)
ScanProperties
Pattern Scanning properties
Fields:
strictMode (series bool): strict scanning mode will check for overflows
logScale (series bool): scan ratios in log scale
errorMin (series float): min error threshold
errorMax (series float)
mintick (series float): minimum tick value of price
PrzRange
Potential reversal zone range
Fields:
patterns (array<string>): array of pattern names for the given XABCD combination
prz (Range): PRZ range
파인 라이브러리
트레이딩뷰의 진정한 정신에 따라, 작성자는 이 파인 코드를 오픈소스 라이브러리로 게시하여 커뮤니티의 다른 파인 프로그래머들이 재사용할 수 있도록 했습니다. 작성자에게 경의를 표합니다! 이 라이브러리는 개인적으로 사용하거나 다른 오픈소스 게시물에서 사용할 수 있지만, 이 코드의 게시물 내 재사용은 하우스 룰에 따라 규제됩니다.
Trial - trendoscope.io/trial
Subscribe - trendoscope.io/pricing
Blog - docs.trendoscope.io
Subscribe - trendoscope.io/pricing
Blog - docs.trendoscope.io
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.
파인 라이브러리
트레이딩뷰의 진정한 정신에 따라, 작성자는 이 파인 코드를 오픈소스 라이브러리로 게시하여 커뮤니티의 다른 파인 프로그래머들이 재사용할 수 있도록 했습니다. 작성자에게 경의를 표합니다! 이 라이브러리는 개인적으로 사용하거나 다른 오픈소스 게시물에서 사용할 수 있지만, 이 코드의 게시물 내 재사용은 하우스 룰에 따라 규제됩니다.
Trial - trendoscope.io/trial
Subscribe - trendoscope.io/pricing
Blog - docs.trendoscope.io
Subscribe - trendoscope.io/pricing
Blog - docs.trendoscope.io
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.