Skip to content
ChartDeck ChartScript docs Account Open the terminal

session

Session information (crypto markets trade 24/7: the session is the UTC day).

#Variables

#session.isfirstbarvariable

true on the first bar of the session (the UTC day).

session.isfirstbar: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.isfirstbar

Since ChartScript 1

#session.isfirstbar_regularvariable

true on the first bar of the regular session (the UTC day).

session.isfirstbar_regular: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.isfirstbar_regular

Since ChartScript 1

#session.islastbarvariable

true on the last bar of the session (the UTC day).

session.islastbar: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.islastbar

Since ChartScript 1

#session.islastbar_regularvariable

true on the last bar of the regular session (the UTC day).

session.islastbar_regular: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.islastbar_regular

Since ChartScript 1

#session.ismarketvariable

true when the bar is inside the regular session (always true for 24/7 markets).

session.ismarket: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.ismarket

Since ChartScript 1

#session.ispostmarketvariable

true in the post-market (never for 24/7 markets).

session.ispostmarket: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.ispostmarket

Since ChartScript 1

#session.ispremarketvariable

true in the pre-market (never for 24/7 markets).

session.ispremarket: bool

Type series bool.

Example

ChartScriptFragmentOpen in editor
const v = session.ispremarket

Since ChartScript 1

#Constants

NameTypeDescription
session.extendedstringThe extended session (same as regular for 24/7 markets).
session.regularstringThe regular session.

The ChartScript documentation is in English for now; translations will follow.