SuperCharting
Sign in Get started Account Open charts

Pine Script v6 compatibility

SuperCharting runs Pine Script v6 indicators and strategies in its own engine. It does not support every Pine feature: this page lists what works, what works with differences, and what is not supported.

Every row below is checked by an automated test suite that runs before each release (last generated 2026-11-03, 69 features: 49 fully, 11 partially, 7 unsupported, 2 not tested). A row only shows its status after its test has passed.

Language

FeatureStatusNotes
Variables, reassignment (:=, +=), several statements on one lineFully
Types, casts and na handling (int, float, bool, string, color, nz, na)Fully
User functions: default arguments, tuples, per-call-site historyFully
Methods (user-defined and built-in method syntax)Fully
Conditionals: if / else if / else, switch, ternaryFully
Loops: for (with step), for...in, while, break, continueFully
Arrays (new, push, get, set, slice, sort, sum, avg, stdev and the rest of array.*)Fully
Matrices (new, set, det, inv, mult, transpose, eigenvalues)Fully
Maps (new, put, get, contains, keys, values, size, remove)Fully
User-defined types (fields, defaults, .new, methods, copy)Fully
Enums (declaration, comparison, input.enum)Fully
Generic collection types (array<T>, map<K, V>, matrix<T>) and objects inside collectionsFully
History references ([n]) on series, variables and function resultsFully
var (initialised once, kept across bars)Fully
varipPartiallyBehaves like var. The chart recalculates a live bar from its start on each update, so a value changed by an earlier tick of the same bar is not kept.
Libraries (import)PartiallyImports work for the bundled TradingView libraries and for libraries saved next to your script. Other authors' published libraries are not downloaded.
Strings (str.format, str.split, str.replace, str.contains, str.tonumber, string concatenation)Fully

Built-in variables and functions

FeatureStatusNotes
indicator() and strategy() declarations (title, short title, overlay)Fully
Inputs (input.int, float, bool, string with options, source, color, timeframe, session, symbol, time, price, text_area, enum)Fully
Plots (plot, plotshape, plotchar, plotarrow, plotcandle, plotbar, hline, fill, bgcolor, barcolor)Fully
Drawings: label, line, box (new, set_*, get_*, delete, all, copy)Fully
Tables (table.new, cell, cell_set_*, merge_cells, clear)Fully
linefill.new (fill between two lines)UnsupportedThe script runs; the fill is not drawn and the Pine Logs panel says so. Plot both levels and fill() between the plots instead.
polyline.newUnsupportedThe script runs; the polyline is not drawn and the Pine Logs panel says so. Draw the segments with line.new() instead.
Alerts: alertcondition() and alert() with frequenciesFully
Logs and runtime errors (log.info / warning / error, runtime.error)Fully
barstate.isfirst, islast, ishistory, isconfirmed, islastconfirmedhistory on historyFully
barstate.isrealtime, isnew on the newest barPartiallyThe newest bar always counts as realtime and unconfirmed, also when the market is closed; TradingView treats a closed market's last bar as history. isnew is always true because every update recalculates the bar from its start.
time, time_close, timestamp(), year/month/hour/minute/dayofweek in the exchange timezoneFullyNSE, BSE and MCX use Asia/Kolkata, US exchanges New York or Chicago time, crypto UTC. Forex and CFD symbols use UTC.
syminfo.timezone, tickerid, ticker, prefix, mintick, currency, type, pointvalueFully
syminfo fundamentals (employees, shares outstanding, sector, industry, analyst targets, recommendations)UnsupportedThey read na (or an empty string) and the Pine Logs panel says so.
session.isfirstbar, islastbar (and _regular)PartiallyWorked out from the bars' dates in the exchange timezone. The newest bar is never "last" because the session close time is not known to scripts.
session.ismarket, ispremarket, ispostmarketPartiallyCharts carry regular-session bars only, so every bar is a market bar; pre-market and post-market bars are not available.
time(timeframe, session) session filters, in the exchange timezone or a given oneFully
timeframe.* (period, multiplier, isintraday, isdaily, in_seconds, change, from_seconds)Fully
request.security on a higher timeframe of the chart's symbol (any expression)FullyThe whole script runs again on the higher timeframe, so indicators, tuples and user functions work there.
request.security with lookahead and gaps (barmerge.lookahead_on/off, gaps_on/off)Fully
request.security on a lower timeframe than the chartPartiallyReturns the chart bar's own value; use request.security_lower_tf for the intrabars.
request.security or request.security_lower_tf with another symbolUnsupportedOnly the chart's own symbol can be requested: data for a second symbol is not loaded into scripts. Workaround: open that symbol on its own chart (a multi-chart layout shows both side by side), or pass the chart's own syminfo.tickerid; other timeframes of the chart's symbol work.
request.security_lower_tf (intrabars)PartiallyReal 1, 5, 15 and 60-minute intrabars for the newest bars; older chart bars get empty arrays.
request.financial, economic, dividends, earnings, splits, quandl, seed, currency_rateUnsupportedWhen the call runs, the script stops with an error that names the function, the line, why, and a workaround. request.currency_rate() returns 1 when no conversion is asked for (the same currency).
ticker.heikinashi (Heikin Ashi bars inside request.security)Fully
ticker.new, ticker.modify, ticker.standard, syminfo.prefix(), syminfo.ticker()Fully
ticker.renko, kagi, linebreak, pointfigureUnsupportedWhen the call runs, the script stops with an error; use ticker.heikinashi() or the standard bars.
ta.sma, ema, rma, wma, rsi, atr, stdev, highest, lowest, change, cum, crossover, crossunderFullyValues compared with independent reference formulas.
ta.macd, bb, stoch, pivothigh, barssinceFullyValues compared with independent reference formulas.
The other ta.* functions (vwap, supertrend, dmi, sar, pivotlow, valuewhen, alma, cci, cmo, cog, correlation, dev, hma, kc, linreg, mfi, mom, percentrank, roc, rci, swma, tsi, vwma, wpr and more)Not testedThey run on every chart; their values are not yet compared with reference formulas in this suite.
math.* and color.* functionsFully

Strategies and backtesting

FeatureStatusNotes
strategy.entry, close, close_all; market orders fill on the next bar's openFully
strategy.exit: stop loss, take profit (price and ticks), trailing stopFully
strategy.order, limit and stop orders, strategy.cancel / cancel_all, OCA groupsFully
Commission (percent, per contract, per order) and slippageFully
Position sizing: fixed, cash, percent of equityFully
Pyramiding (0 and 1 allow one entry per direction, N allows N)Fully
process_orders_on_close, margin calls, strategy.* state variables and closedtrades/opentrades functionsFully
Intrabar fill assumption for stops and limitsPartiallyLike TradingView without the bar magnifier: price moves open, then the extreme nearer the open, then the other extreme, then close.
Bar magnifier (use_bar_magnifier) and other ignored strategy() settings (close_entries_rule, fill_orders_on_standard_ohlc, backtest_fill_limits_assumption, risk_free_rate)UnsupportedThe strategy runs and the Pine Logs panel names each setting that is ignored, with a workaround.
calc_on_every_tick and live (realtime) strategy updatesPartiallyHistory is calculated once per bar. On a live chart the strategy recalculates as new prices arrive, at most every few seconds when the server is busy.
strategy.risk.* rulesNot testedThe functions are accepted; their effect is not yet compared with TradingView in this suite.

Repainting and realtime behaviour

FeatureStatusNotes
Lookahead off: a higher-timeframe value appears on the bar where that higher bar closesFully
Lookahead on: the finished higher-timeframe value on every bar of that period (future leak, as on TradingView)Fully
Gaps on / off (barmerge.gaps_on returns na between higher-timeframe closes)Fully
Realtime vs historical bars and intrabar updatesPartiallyHistorical bars are calculated once, at their close. The newest bar is recalculated as prices arrive (not on every single tick when the server is busy), and variables are rolled back between updates, so realtime results match TradingView's for scripts that do not use varip.
Alert timing (alert.freq_once_per_bar, once_per_bar_close, all; alertcondition)PartiallyServer alerts check conditions as new prices arrive; once-per-bar-close alerts fire when the bar closes. Checks run at most every few seconds, not on every tick.

Engine limits and protection

FeatureStatusNotes
Infinite and very long loops stop with a clear errorFully
Memory: huge arrays and runaway allocation stop with a clear errorFully
Time limit per runFullyA script that needs longer than the limit stops with "ran out of time".
Malformed scripts: syntax errors name the lineFully
Deep recursion and oversized strings stop with a clear errorFully

Unsupported functions and their workarounds

FunctionWhyWorkaround
request.financial()Company financial statements (revenue, EPS, ratios) are not available to scriptsEnter the figure you need as an input, e.g. input.float()
request.economic()Economic indicators (GDP, CPI, rates) are not available to scriptsEnter the figure you need as an input, e.g. input.float()
request.dividends()Dividend data is not available to scriptsEnter the amounts or dates as inputs
request.earnings()Earnings data is not available to scriptsEnter the amounts or dates as inputs
request.splits()Split data is not available to scriptsEnter the split ratio as an input
request.quandl()This external data source is not available (it is deprecated in Pine as well)Enter the values you need as inputs
request.seed()Pine Seeds data repositories are not availableEnter the values you need as inputs
request.currency_rate()Currency conversion rates are not available to scriptsMultiply by a rate entered as an input
ticker.renko()Scripts cannot build Renko barsUse ticker.heikinashi(), which is supported, or the standard bars
ticker.kagi()Scripts cannot build Kagi barsUse ticker.heikinashi(), which is supported, or the standard bars
ticker.linebreak()Scripts cannot build Line Break barsUse ticker.heikinashi(), which is supported, or the standard bars
ticker.pointfigure()Scripts cannot build Point & Figure barsUse ticker.heikinashi(), which is supported, or the standard bars
linefill.new()Fills between two lines are not drawnPlot both levels and fill() between the two plots
polyline.new()Polylines are not drawnDraw the segments with line.new()

When a script uses something unsupported

For the unsupported features listed here, a script gets a clear message instead of a silently wrong answer. A function whose result would be wrong, such as company financials or data for a second symbol, stops the script with an error naming the function, the line, why it is not supported, and a workaround. Drawings that cannot be shown yet (fills between two lines, polylines) and strategy settings that are ignored let the script run, and the Pine Logs panel in the Pine Editor says what was left out.

Time zones

Time functions such as hour, dayofweek, timestamp() and session filters use the exchange’s time zone, as Pine does: India (NSE, BSE, MCX) uses IST, US exchanges New York or Chicago time, crypto UTC. Forex and CFD symbols use UTC.

Engine limits

To keep the site fast for everyone, a script stops with a clear error if a single loop runs more than 100,000 times, if it allocates too much memory (an array holds at most 100,000 elements), if functions recurse too deeply, or if one calculation takes longer than the time limit.

Pine guides Data coverage