BarsSinceCompare
|
Trading system toolbox |
SYNTAX | BarsSinceCompare( past, comparison, current ) |
RETURNS | ARRAY |
FUNCTION | For every bar in current array, go back in time and compare past array values with current bar value and get number of bars since comparison was true.
Parameters:
For more discussion about that function see: https://forum.amibroker.com/t/duplicate-bars-since-price-was-this-high-low/28355/14 |
EXAMPLE | // get bars since close was last time higher than current close
|
SEE ALSO | BarsSince() function |
The BarsSinceCompare function is used in the following formulas in AFL on-line library:
See updated/extended version on-line.