Function reference
Bar states, time, timeframe, session
What the script knows about the bar, the chart and the clock. The feed trades 24x7 on UTC.
41 names from PineTS 0.11.1 · 8 with full entries
barstate.islast
Verifiedbarstate.islasttrue on the last bar on the chart.
barstate.isconfirmed
Verifiedbarstate.isconfirmedtrue once a bar has closed. Use for signals that must not change.
barstate.isfirst
Supportedbarstate.isfirsttrue on the first bar.
barstate.isrealtime
Supportedbarstate.isrealtimetrue on bars that formed while the chart was open.
timeframe.period
Supportedtimeframe.periodThe chart's timeframe as a Pine string, for example "5" or "15S".
timeframe.in_seconds
Supportedtimeframe.in_seconds(timeframe)
A timeframe string in seconds.
timeframe.change
Supportedtimeframe.change(timeframe)
true on the first chart bar of a new higher-timeframe bar.
runtime.error
Supportedruntime.error(message)
Stops the script with your message, shown in the console.
Everything else in Bar states, time, timeframe, session
Also implemented. These follow TradingView’s Pine v6 reference for their arguments.
- barstate.ishistorySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- barstate.islastconfirmedhistorySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- barstate.isnewSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.from_secondsSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isdailySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isdwmSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isintradaySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isminutesSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.ismonthlySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.issecondsSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isticksSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.isweeklySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.main_periodSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- timeframe.multiplierSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.isfirstbarSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.isfirstbar_regularSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.islastbarSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.islastbar_regularSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.ismarketSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.ispostmarketSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- session.ispremarketSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.heikinashiSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.inheritSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.kagiSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.linebreakSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.modifySupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.newSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.pointfigureSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.renkoSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- ticker.standardSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- log.errorSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- log.infoSupportedImplemented. Arguments as in TradingView's Pine v6 reference.
- log.warningSupportedImplemented. Arguments as in TradingView's Pine v6 reference.