Peak
|
Basic price pattern detection |
SYNTAX | Peak(ARRAY, change, n = 1) |
RETURNS | ARRAY |
FUNCTION | Gives the value of ARRAY n-th peak(s) ago. This uses the Zig Zag function (see Zig Zag) to determine the peaks. n =1 would return the value of the most recent peak. n =2 would return the value of the 2nd most recent peak. Caveat: this function is based on Zig-Zag indicator and may look into the future. |
EXAMPLE | peak(close,5,1) |
SEE ALSO |
Tomasz Janeczko tj --at-- amibroker.com 2003-02-13 04:02:04 | Zig/Peak/Trough functions work correctly for ARRAYS containing data greater than zero. |
The Peak function is used in the following formulas in AFL on-line library:
See updated/extended version on-line.