Sidechair

table.set_frame_color()

Browse the reference

Sets the color of the rectangle drawn around the outer edge of a table.

Try it in the editor

The frame wraps the whole grid and is separate from the lines between cells. It is drawn only while the frame width is above 0, so recoloring alone changes nothing visible.

An accent color on the frame makes a small panel stand out from the candles without filling it.

Syntax

Pine Script
table.set_frame_color(table_id: series table, frame_color: series color (optional)) -> void
table.set_frame_color(frame_color: series color (optional)) -> void

Arguments

NameTypeDefaultDescription
table_idseries tablerequiredThe table whose outer frame is recolored.
frame_colorseries colornaColor of the outline around the table. na hides it; it also stays hidden while the frame width is 0.

Returns

Nothing.

Example

Pine ScriptBlue frame on a stats panelOpen in editor
//@version=6
indicator("table.set_frame_color: accent", overlay = true)
var t = table.new(position.top_left, 1, 1, frame_width = 2)
if barstate.islast
    table.cell(t, 0, 0, "Stats")
    table.set_frame_color(t, color.blue)

See also

Runs on Sidechair