AroonUp
AroonUp in ProBuilder measures how many bars have passed since the highest high of the last N periods, scaled 0 to 100. Syntax, formula, worked examples.
Syntax
AroonUp[N]Parameters
| Name | Type | Default | Description |
|---|---|---|---|
N | integer | 25 | Number of bars scanned for the most recent highest high. Shorter windows react faster but produce more flips; 25 is the common textbook setting. |
Formula
AroonUp = 100 * (N - BarsSinceHighestHigh) / NBarsSinceHighestHigh is the number of bars elapsed since the highest high within the last N bars. A new high on the current bar yields 100. A high that occurred N bars ago yields 0.
How it works
AroonUp measures the age of the most recent significant high. On each bar it scans the last N bars, finds the highest high, and expresses the time since that high as a percentage of the window. Frequent new highs keep the line near 100; a market that has stopped making highs lets the line decay toward 0 in steps of 100/N per bar.
The measurement is purely temporal. The size of the new high is irrelevant, only its recency counts. This makes AroonUp an early detector of trend initiation: a market breaking out of a base starts printing new highs immediately, driving the line to 100 well before slope-based indicators respond.
AroonUp is designed to be read alongside AroonDown, which applies the same logic to lows. The dominant line identifies the prevailing pressure, and crossovers between the two lines are the standard trend-change signal of the Aroon system.
Examples
Example 1, Threshold signal from AroonUp (Indicator)
// Classify the 20-bar window by freshness of its highest high
N = 20
myAroonUp = AroonUp[N]
IF (myAroonUp > 50) THEN
SIGNAL = 1
ELSE
SIGNAL = -1
ENDIF
RETURN SIGNALReturns 1 while the highest high of the last 20 bars falls in the recent half of the window, and -1 otherwise. The raw building block for an uptrend filter.
Example 2, Screening for established uptrends (ProScreener)
// Instruments printing recent highs while lows grow stale
au = AroonUp[25]
ad = AroonDown[25]
SCREENER[au > 70 AND ad < 30](au AS "AroonUp")Returns instruments where the 25-bar high is fresh and the 25-bar low is old, the textbook Aroon definition of an uptrend.
Example 3, Long entry on Aroon crossover (ProBacktest)
// Buy when upward pressure overtakes downward pressure
au = AroonUp[25]
ad = AroonDown[25]
IF NOT LongOnMarket AND au CROSSES OVER ad AND au > 70 THEN
BUY 1 CONTRACT AT MARKET
ENDIF
IF LongOnMarket AND ad CROSSES OVER au THEN
SELL AT MARKET
ENDIFOpens a long when AroonUp crosses above AroonDown with a strong reading and exits when the relationship inverts. Requiring au > 70 at the cross skips signals that occur while both lines drift mid-range.
Interpretation
| Range | Reading |
|---|---|
| 70 to 100 | The highest high is recent. Upward pressure is active. |
| 30 to 70 | Mixed. The last high is aging without being replaced. |
| 0 to 30 | No new high for most of the window, upward pressure has faded. |
The strongest statements come from the pair: AroonUp above 70 with AroonDown below 30 marks an established uptrend, while both lines in the middle of the range indicate consolidation. Both lines simultaneously high mean the window contains both a fresh high and a fresh low, a volatile, undecided market.
Common errors and gotchas
- No price argument. The period goes in square brackets and nothing else is accepted.
AroonUp[20](close)fails to compile, the calculation always runs on the high price series. - A stalled line is information, not an error. After a single strong high, AroonUp decays linearly for up to
Nbars even if price stays elevated. A falling AroonUp does not mean price is falling, only that the high is aging. - Magnitude blindness. A one-tick marginal high resets the line to 100 exactly like a major breakout does. In slow drifts this exaggerates trend strength; a companion filter such as
ADXor a minimum range condition adds the missing magnitude check. - Window length changes the meaning.
AroonUp[5]reports on a completely different structure thanAroonUp[100]. Thresholds like 70/30 are conventions for the 25-bar default and need re-validation when the period changes.
Related instructions
AroonDown, the companion line measuring bars since the lowest low.ADX, trend-strength measure that complements Aroon direction readings.DIplus, directional movement component for upward moves.DIminus, directional movement component for downward moves.HighestBars, returns the number of bars since the highest value directly.LowestBars, returns the number of bars since the lowest value.Highest, the highest value over a lookback window.Supertrend, trend-following level often paired with directional tools.
