Indicators/probuilder · probacktest · proorder · proscreener

PRTBANDSSHORTTERM

PRTBANDSSHORTTERM returns the short-term band of the proprietary PRT Bands indicator in ProBuilder. Syntax, hook-pattern screener example, gotchas.

Syntax

probuilder
PRTBandsShortTerm

The function takes no parameters and no price argument. It always reflects the PRT Bands calculation on the instrument and timeframe of the chart or scan it runs on.

Formula

The PRT Bands are a proprietary indicator developed by ProRealTime™. The exact formula is not published, so it cannot be reproduced or re-implemented in custom code. PRTBandsShortTerm simply exposes the value of the short-term component as computed internally by the platform.

How it works

The PRT Bands consist of several lines: an upper and lower band that frame price, plus medium-term and short-term lines that track the trend at different speeds. PRTBandsShortTerm returns the short-term line, the one that hugs price most closely and reacts first when direction changes.

Because the function returns a numeric series, it supports the standard bar-offset syntax. PRTBandsShortTerm[1] is the value one bar ago, PRTBandsShortTerm[2] two bars ago, and so on. Assigning the value to a variable first, then offsetting the variable, keeps code readable and avoids repeating the call.

Typical uses include detecting hooks (a local turn in the line), comparing the short-term line against the medium-term line for trend agreement, and filtering signals from other indicators so they only fire when the short-term band points the right way.

Examples

Example 1, Ascending hook screener (ProScreener)

probuilder
// List instruments where the short-term band just turned up
a = PRTBandsShortTerm
result = a > a[1] and a[1] < a[2]
screener[result]

The line was falling two bars ago and is rising now, which defines an ascending hook. The scan returns every instrument where this turn happened on the latest bar.

Example 2, Slope and distance from price (Indicator)

probuilder
// Plot the short-term band slope and the gap between price and the band
st = PRTBandsShortTerm
slope = st - st[1]
gap = close - st
RETURN slope AS "ST band slope", gap AS "Close minus ST band"

A positive slope means the short-term band is rising. The gap series shows how far price has stretched away from the band, which can flag overextension.

Example 3, Trend filter for entries (ProOrder)

probuilder
// Only take long entries while the short-term band is rising
st = PRTBandsShortTerm
rising = st > st[1]

IF NOT LongOnMarket AND rising AND close CROSSES OVER Average[20](close) THEN
  BUY 1 CONTRACT AT MARKET
ENDIF

IF LongOnMarket AND st < st[1] THEN
  SELL AT MARKET
ENDIF

The moving-average crossover only triggers a position when the short-term PRT Band confirms upward direction, and the position closes when the band turns down.

Interpretation

ReadingMeaning
Line risingShort-term pressure is upward.
Line fallingShort-term pressure is downward.
Ascending hook (down then up)Possible start of a short-term upswing.
Descending hook (up then down)Possible start of a short-term downswing.

The short-term line reacts faster than PRTBandsMediumTerm and the outer bands, so it also produces more false turns. Combining it with the medium-term line or the outer bands, and acting only when they agree, is the common way to reduce noise.

Common errors and gotchas

  • Adding brackets or arguments. PRTBandsShortTerm[14](close) is invalid. The function is parameterless, the platform fixes the calculation internally. Only the bar-offset syntax such as PRTBandsShortTerm[1] is accepted, and there it means one bar back, not a period setting.
  • Trying to rebuild the formula. Since the PRT Bands formula is proprietary, no combination of averages or standard deviations reproduces it exactly. Code that assumes the band equals some documented formula will drift from the platform's plotted values.
  • Hook patterns repaint on the live bar. On the current, unfinished bar the value keeps updating, so a hook detected intrabar can disappear by the close. Screeners and strategies that must not repaint should evaluate confirmed bars, for example by comparing a[1], a[2] and a[3].
  • Whipsaws in flat markets. In ranges the short-term line flips direction frequently. Using it alone as an entry trigger generates many small losing signals, a higher-timeframe or medium-term filter is usually required.