Bar Close

The close price and the close time of a bar.

Role in the strategy

SlotAvailableRole
Entry PointNo—
Entry RuleNo—
Exit PointYesCloses positions at the bar close price.
Exit RuleNo—

Bar Close is the default exit point of a new strategy. It has no parameters and produces no conditions: it always allows closing, so a position closes at the close of the current bar unless an exit rule or a strategy feature (Stop Loss, Take Profit, …) closes it earlier.

As an exit point it is a market exit, so the strategy may carry Exit Rules in front of it — the rules allow or deny the exit and the position still closes at the bar close price.

Bar Close is in the Generator exit-point pool next to Bar Open. It is the point the Generator draws where the market closes every session (stocks, session-bound indices), because there the session close is a real event; on a continuously trading market the Generator leaves Bar Close out in favour of Bar Open.

Logic rules

  • Exit Point: Exit at Bar Close.

Parameters

None.

Calculation

The price component mirrors the bar close price series of the data set (engine/indicators/indicator-bar-close.ts). There is no chart line: the closing price itself is the bar close.

Backtesting

The entry and exit point together select the per-bar simulator (see engine/backtester/backtester-core.ts):

Entry pointExit pointScenario
Bar OpenBar CloseOpenClose
other indicatorBar CloseIndicatorClose
  • A position is closed at the bar close price.
  • When no exit rules are added, the strategy exits at the first bar close after entry; exit rules restrict the exit, and strategy features can close earlier (or later when Max Position Duration holds the position).