v4 Heavy revision in order to use more shallow User Defined Types (UDTs).
Added:
createRow(contents, height, tooltip)
Creates a new row with an array of cells containing the given contents.
Parameters:
contents: An array of strings representing the cell contents.
height: The height of the row.
tooltip: The tooltip of the row.
Returns: A new Row object.
updateRow(t, row, cells, tooltip)
Updates a row of cells in a table with the given cell content.
Parameters:
t: The table to update.
row: The index of the row to update.
cells: The array of cell content to set in the row.
tooltip: The optional default tooltip to use if the cell's value is na.
style(t, firstCol, lastCol, firstRow, lastRow, bgColor)
Styles the cells in the given range of the table with the given background color while automatically chosing a foreground color.
Parameters:
t: The table to style.
firstCol: The index of the first column in the range.
lastCol: The index of the last column in the range.
firstRow: The index of the first row in the range.
lastRow: The index of the last row in the range.
bgColor: The background color to apply.
styleColumns(t, first, last, bgColor)
Parameters:
t
first
last
bgColor
styleColumn(t, col, bgColor)
Parameters:
t
col
bgColor
styleRows(t, first, last, bgColor)
Parameters:
t
first
last
bgColor
styleRow(t, col, bgColor)
Parameters:
t
col
bgColor
CellAlign
Fields:
horizontal
vertical
CellStyle
Fields:
bgColor
width
height
TableSize
Fields:
columns
rows
Updated:
addCell(row, contents, format, tooltip)
Adds a new cell with the given integer contents to the row.
Parameters:
row: The row to add the cell to.
contents: The contents of the new cell, an integer.
format: The format string for the integer.
tooltip: The tooltip of the new cell.
Returns: The new Cell object.
addRow(rows, contents, height, tooltip)
Adds a new row to the array of rows using the given array of cell contents.
Parameters:
rows: An array of rows.
contents: The array of cell contents to use for the new row.
height: The height of the new row.
tooltip: The tooltip of the new row.
Returns: The new Row object.
updateStyle(t, style)
Updates a PineScript table with the style properties of the given TableStyle.
Parameters:
t: The PineScript table to update.
style: The TableStyle containing the style properties to apply.
initialize(rows, position, border, frame)
Initializes a new PineScript table with the given data rows and table style.
Parameters:
rows: An array of Rows to populate the table with.
position: The position of the table within the chart.
border: The optional border style for the table.
frame: The optional frame style for the table.
Returns: The new PineScript table.
Removed:
create(position, style)
Creates a new table with an optional style.
equals(a, b)
Determines if two TableStyles are equal.
inherit(child, parent)
Creates a TableStyle with the same property values as the child but inherits properties from the parent if the child property is na.
getStyleChange(child, parent)
Creates a TableStyle that only uses property values from the child that differ from the parent.
addColumn(table, style)
Adds a new column to the given table with optional style.
gridSize(tbl)
update(pineTable, tbl)
Updates an existing PineScript table with the data and style from a Table object.
build(tbl)
Builds a table in PineScript based on a given Table object. Any values that are 'na' will simply not be set.
Column