Definition
Number of consecutive completed calendar periods (America/New_York; period is Year, Quarter or Month), ending with the last completed period, whose closing value of the inner indicator was strictly higher (ConsecutiveIncrease) or strictly lower (ConsecutiveDecrease) than the previous period's closing value. A period's closing value is the inner indicator's last non-null value observed in that period. The in-progress current period never counts, equal values are not a change, and a completed period with no value breaks the streak. The count is capped at lookback (an integer from 1 to 60). Returns null when no completed period has a value.
Parameters
Inner indicator, Period (Year, Quarter or Month), Lookback (1–60)
Output range: 0 to lookback, or null when no completed period has a value
Example condition
`ConsecutiveIncrease(LastDividend(KO), Year, 10) >= 10` (KO raised its regular dividend per share in each of the last 10 completed years); `ConsecutiveIncrease(Fundamental(AAPL, totalRevenue), Quarter, 8) >= 4` (AAPL's reported revenue rose for at least the last 4 completed quarters)Usage notes
Inside a DynamicRebalance filter, pass the candidate to the inner indicator to screen for dividend growers or steady revenue growers. Set lookback to the streak you compare against, since the count never exceeds it.
Use in a strategy
Add this indicator to a strategy condition, choose its supported parameters and compare the output with the threshold required by your rule. Preserve the same interval and lookback when comparing backtests.
After saving the condition, inspect its asset, interval, lookback and comparison operator against the parameters above. If no trades occur, check whether the condition ever became true and whether the requested input data exists for that period. A missing input is not a zero-valued signal. An indicator produces an input to a rule. It does not establish future returns, and data availability can differ across assets and periods.