1. Home
  2. Docs
  3. pjsProfileBars
  4. General feature notes
  5. Algo bars

Algo bars

Algo bars are an innovative feature that allows you to write your own alerts and signals, without coding, compiling, etc.

Below, you can see one set of example conditions for a signal

Enable
Globally enables or disables the signal

The chart marker option places the text in the Signal name field onto the chart as a native Ninjatrader test object (for interaction with third-party tools), above or below the bar, as set in the options.

Condition #x
Conditions are the criteria you want to match for the signal to be generated. All signals must be true for the event to trigger.

Comparison conditions typically consist of 3 or more parts (depending on the comparison).
A variable name or other value, a comparison operator, and a variable name or value.
There must be 1 (or more) spaces between the condition parts. For example

VOLUME > 500

Some logical comparitors, such as && and ||, are also supported and can be combined if needed.
More than 1 term can be joined with either ‘&&’ or ‘||’ (AND or OR), for example,

For example

VOLUME > 500 && CLOSE < OPEN

or

CLOSE > OPEN && CLOSE > VPOC

The full list of supported location operators is  “>”, “<“, “>=”, “<=”, “==”, “!=”, “~~”, where ~~ means ‘close enough’. It is an approximate rather than an exact match

The ’26 release added support for some simple arithmetic operations such as “/”, “*”, “+”, “-“.
For example

CLOSE > OPEN + 5

In addition, parentheses for evaluation order are now supported, so it is possible to use them either to force evaluation order or for clarity

(CLOSE / OPEN) > 0.05

At the time of writing this document, the following variable names are supported (This list was significantly updated for the ’26 release)

CLOSE
DELTA
DELTARANK
DELTAPERCENT
VOLRANK
SESSIONPOC
SESSIONVAH
SESSIONVAL
SESSIONVWAP
DURATIONS (bar duration in seconds)
DURATIONMS
VPOC (bar vpoc)
VAH (bar vah)
VAL (bar val)
DPOC (bar delta poc)
ALGOBARSCUSTOMVALUE1 (a customisable value to be used in expressions)
IMBALANCEUPVOLUME (the bar total imbalance volume)
IMBALANCEDNVOLUME
IMBALANCEUPPERCENT (the bar total imbalance %)
IMBALANCEDNPERCENT
MAXDELTAATPRICE (the max delta at any single price in the bar)
HASIMBALANCEUP (returns 1 or 0)
HASIMBALANCEDN (returns 1 or 0)
DELTAIMBALANCEPERCENT
TAILSIZE (the size of the bar tail, in points. Represents the low wick if an up up close, and the high wick if a down close)
VOLUME
HIGH
LOW
OPEN
VWAPAVG
VWAP (bar vwap)
SIGNALSUM (the SUM of ‘signals’ triggered on this bar. Bearish signals have a value of -1, bullish 1)
COTDELTAHIGH
COTDELTALOW|
TRMODE (sets ‘trend’ or ‘regression’ mode)

Some values may be queried for historical values in the typical NinjaTrader fashion using BarsAgo
HIGH[x]LOW[x]OPEN[x]CLOSE[x]VOLUME[x]DELTA[x]DELTARANK[x]VOLRANK[x]VPOC[x]

A special variable is PLOT[x[x]], which can query third-party indicator values via their exposed plots. This plot must be on the same chart as pjsProfilebars and is accessed via the plot name and its barsAgo value, for example. Note – Ninjatrader itself does not guarantee the order of update of indicators on the chart.

Voice alert
The voice announcement you want when the criteria is met, at the close of bar

Audio alert
The custom audio alert you want (.wav file) played when the criteria is met, at the close of bar

Chart marker
If checked, the signal name will be printed on the chart. This option uses a native text object (so that third-party indicators can also read it), so it may affect performance if you are generating thousands of them.

Chart marker brush
Custom colouring for the chart markers

Above bar?
You have the choice of placing any chart market above or below the bar

Paint bar
Will paint the body of the bar where the signal is generated

Paint background
Will colour the background of the chart on the bar where the signal is generated

Signal name
This is the custom signal name you give to this set of criteria

Take trade (buy & sell)
These options will trigger trades, but only if you have the algo helper enabled and armed. The algo helper enables you to semi-automate your entries or exits based on the trigger of your criteria in the algobars conditions.

This list has been updated since it was originally written with newly supported terms from new releases.

Nice examples and advice are often shared in the Discord.

How can we help?