na there: a line or an area breaks (a gap), and a plot that says join: true is drawn straight across the bars it has no value on. Histograms and points draw nothing on such a bar.
plot
Dots or crosses at each value, with no line between them unless they are joined.
A shape, a label or a character on the bars where
set says so.Arrows sized by their value, as Pine’s
plotarrow: up below the bar for a value above 0, down
above it for one below, none for 0 or na. An arrow’s height runs from minHeight to
maxHeight by its value’s size against the largest on the bars in view. set’s colour
replaces up or down on that bar.(title: string, a: Plot | LevelPlot, b: Plot | LevelPlot, options?: { color?: Color | null; /** * A gradient in place of the fill's one colour, from the highest edge of each stretch of the * fill to its lowest (`{ top, bottom }`), or from its left to its right. A colour set on a bar * with the fill's `set` still paints that bar. */ gradient?: Gradient; showLast?: number; hidden?: boolean; }): FillPlot
Shade between two plots or levels of this script, optionally per bar. Between two levels it
is a band across the whole pane. A fill takes the offset of its first plot, colours included.
(title: string, options?: { pane?: PaneName; offset?: number; showLast?: number; hidden?: boolean }): ColorPlot
Shade the whole height of the pane behind a bar.
(title: string, price: number, options?: { color?: Color | null; style?: LineStyle; width?: LineWidth; pane?: PaneName; hidden?: boolean }): LevelPlot
A horizontal line across the pane, such as 70 on an RSI. Returns a handle a fill can use.
Recolour the chart’s own candles, bodies, borders and wicks, as Pine’s
barcolor does.
null leaves a bar in the chart’s colours. Chart types without candles (footprints) say in
the legend that it does not apply there.Cells inside each bar, such as a footprint (bid × ask per price row) or a bar’s own volume
profile: rows of price bands with widths, colours and numbers, set from the chart’s handlers
with
add. Cells never stretch the price scale.A footprint of the script’s own: amounts by price in up to 4 named lanes, drawn by the
footprint chart type as a Data choice beside Bid × Ask, with its rows, shapes, colours and
statistics rows. One per script. On a candle chart nothing is drawn, and the legend offers to
switch to the footprint.
A heat of the script’s own: amounts by time and price, drawn behind the candles by the order
book heatmap’s painter, one column a bar, rows grouped with the zoom and toned on the view’s
own scale. One or two sides; the chart carries values into later bars (
carry). One per script.PlotOptions
Hide from the chart, and from the legend’s values. With
legend: false too, a reading kept
for list columns (the watchlist, In play): never drawn, and a column starts on it.Show the last value as a tag on the price axis, without the line across the chart that
trackPrice adds. Default: false on the price pane, true in the script’s own pane.The scale margins of the scale this plot sits on, as fractions of the pane, such as
{ top: 0.2, bottom: 0.28 }.Draw on a hidden scale of its own inside the pane, between these fractions from the top and
the bottom, such as volume at the foot of the price pane:
{ top: 0.84, bottom: 0 }.A fixed scale from
min to max instead of autoscaling, such as { min: 0, max: 100 }.false: the plot is drawn at its values but does not stretch its scale, which fits the rest
of the pane (the candles, on the price pane). For levels far from price, such as liquidation
clusters, that would otherwise squash the candles into a line; parts outside the view are
simply not seen. Default true.A short name the legend writes before this plot’s value, such as
'Sell', at most 24
characters. Without one the value stands alone, as the built-in studies’ values do. Narrow
charts leave the names out and keep the values. false draws the plot with no value in the
legend, for a column whose value other plots name.Draw only the newest this many bars, a whole number from 1, as Pine’s
show_last. Default: every bar.Draw the plot shifted by this many bars, a whole number from -500 to 500. The value set on
bar
i is drawn on bar i + offset: a positive offset shifts the plot right, and its last
values are drawn past the newest bar, in the empty space to its right (Ichimoku’s leading
spans); a negative one shifts it left (the lagging span). The legend reads the value drawn
at the bar under the crosshair. Default 0.JoinOptions
Draw the line (and the area’s fill) across bars where the plot is
na, from the last value
to the next. Default false: the plot breaks there, as Pine’s plot.style_linebr and
style_areabr do. Pine’s style_line, style_stepline and style_area join, and the
translation of a pasted Pine script says so.Gradient
A gradient in place of a colour:{ top, bottom } runs down the shape it fills, \{ left, right \} across it. Leave one end out to fade the other end’s colour to nothing.
Fill
A colour, or a gradient between two.LinePlotOptions
A soft glow in the line’s own colour, drawn under it:
true for 8px of blur, or 1 to 24px.
It follows the line’s colours bar by bar and breaks where the line does.A staircase: flat from each value to the next bar’s, then straight up or down, as Pine’s
plot.style_stepline. 'diamonds' also marks each change of value with a diamond.HistogramPlotOptions
Bars this many pixels wide, as Pine’s
plot.style_histogram. Leave it out for columns as
wide as the bar, as plot.style_columns.AreaPlotOptions
Fill from the line to this value, as Pine’s area fills to its
histbase. Leave it out for a
wash that fades to the foot of the pane.PointsPlotOptions
CandlePlotOptions
OHLC bars, a tick left for the open and right for the close, as Pine’s
plotbar. Default: candles.The wicks’ colour, and the bodies’ outline;
null draws none. Default: the body’s colour.ArrowsOptions
Plot
The value for the current bar, optionally with this bar’s colour.
LevelPlot
A horizontal line across the whole pane (plot.level). It can be one side of a plot.fill.
set moves it: the line is drawn at the price in effect on the newest bar, across every bar.
ShapePlot
(condition: boolean, options?: { price?: number; text?: string; color?: Color | null; textColor?: Color | null }): void
Draw the shape on the current bar when
condition is true. price is used with
location: 'absolute'; text and color replace the plot’s own for this bar.ShapeOptions
The text’s colour. Default: the shape’s colour; inside a label, black or white, whichever reads on it.
Kept in the declaration but not drawn, like a plot’s
hidden.Marker
MarkersPlot
ColorPlot
FillPlot
Shade this bar with a gradient of its own, as Pine’s gradient
fill: topColor at the price
top and bottomColor at bottom, each colour held past its price. null fades that end
to nothing.CandlePlot
(bar: { open: number; high: number; low: number; close: number }, color?: Color | null, colors?: { wick?: Color | null; border?: Color | null }): void
colors gives this bar’s wick and border colours; null draws none, and leaving one out keeps the plot’s own.CellAlign
The edge a cell’s width grows from, which its number lines up with too.BarCell
One cell of a cells plot: a price band inside a bar, with a width, colours and a number.How wide the cell is, as the plot’s
scale says; leave it out to fill the column. Zero or
less draws no fill, only the border and the number.'left' (the default) grows the cell from the column’s left edge, 'right' from its right edge, 'center' both ways.CellsPlot
Add a cell to the current bar. Each run of a bar starts with none, so add every cell the bar
should show; a bar holds at most 1,024 cells, and a plot 250,000 over every bar (the oldest
bars lose theirs first).
FootprintLane
One lane of a footprint: what it holds, where it sits and its colour.Left or right of the bar’s candle, at most 2 lanes a side. On each side the first lane
declared sits nearest the candle.
'size' (the default): amounts in the market’s base unit, printed in the chart’s USD or coin
unit as Bid × Ask is. 'count': amounts printed as they are, such as a number of orders.FootprintOptions
Up to 2 pairs of a left lane (
a) and a right lane (b) whose imbalances are marked, as Bid
× Ask marks buying against selling. compare: 'row' (the default) weighs the two at the same
price; 'diagonal' weighs b at a price against a one row below, which fits only taker
selling against taker buying. Leave it out and the footprint marks no imbalances.The statistics rows offered first under the bars, up to 8: a lane’s id is that lane summed
over the bar, and
{ net: [a, b], label } is lane a less lane b. Default: every lane.FootprintPlot
Add
amount to lane at price on the trade’s bar. Call it from an event handler, such as
trades().onTrade: a forming bar’s onBar runs again, so it would count trades twice.
Prices snap to the market’s step and amounts at one price add up. 0 and na are left
out; an amount below 0 is an error, so split a signed value into two lanes.HeatSide
One of a heat’s two sides: what it holds and its colour.Its colour, shaded by amount. Default
color.down for the first side and color.up for the second.HeatCarry
How the chart carries a heat’s values into later bars, since a bar’s own trades sit under its candle.{ fade: n } halves a value every n bars (1 to 200); 'hold' keeps it at full
strength until a later bar’s range covers its price; 'none' draws each bar’s own values only.
HeatCommonOptions
'size' (the default): amounts in the market’s base unit, read out in USD and coin.
'count': amounts read out as they are, such as a number of prints.The carry the heat starts with,
{ fade: 10 } by default. The trader can change it in the heat’s settings, without a rerun.HeatOptions
A ramp of this hue. Leave it out for the theme’s heat ramp, the order book heatmap’s blue to gold.
HeatSidesOptions
Exactly 2 sides. The first is the negative one: with
combine: 'net' it is subtracted.How a row’s two sides meet.
'net' (the default): they cancel, so a balanced row is quiet and
the rest shows in the larger side’s colour. 'larger': the row’s total, in its larger side’s colour.HeatPlot
Add
amount at price on the event’s bar; with two sides, add(side, price, amount). Call
it from an event handler, such as trades().onTrade: a forming bar’s onBar runs again, so
it would count trades twice. Prices snap to the market’s step and amounts at one price add
up. 0 and na are left out; an amount below 0 is an error, so give a signed value two sides.CellsOptions
What a full-width cell means:
'bar' (the default) the largest weight on its own bar,
'visible' the largest on the bars in view, 'unit' a weight of 1 (weights are 0 to 1).The chart’s own candles while the cells show:
'overlay' (the default) leaves them behind
the cells, 'side' draws each as a thin strip at the left of its bar, 'hidden' draws none.
Only on the price pane of a chart that draws candles.How numbers are written:
'compact' (the default) shortens them, 3.21K; 'fixed' writes them
in full, 3214.56; 'percent' reads them as a fraction, 0.153 as 15.3%. A cell too small for
its number drops decimals, then shortens it, then shows none.The default fill, border and number colours. Without a fill a cell is the theme’s study colour.