Table.new
Table.newcolumns
Group: Constants
Documentation
Creates a new table from a set of columns. This can either be provided as a set of pairs of names and data, or existing Column objects.
Arguments
columns: A set of either Column objects or pairs of name and data to construct a column from. If passing name and data, the items can be passed as a Vector, Range or a Date_Range.
Returns
- A Table of all of the input data.
 
Examples
Create a new table with the specified columns.
      first_column = ["count", [1, 2, 3]]
      second_column = ["is_valid", [True, False, True]]
      Table.new [first_column, second_column]
Returns a table like:
| count | is_valid | 
|---|---|
| 1 | True | 
| 2 | False | 
| 3 | True | 
? Unique Names Column names must be unique. If a column name is repeated, an error is thrown.
? Consistent Row Count All columns must have the same number of rows. If a column has a different number of entries, an error is thrown.
Errors
- If the vector is improperly defined, an error is returned.
 - If there are no columns, an error is returned.
 - If column names are not distinct, an error is returned.
 - If any columns have an inconsistent number of records, an error is returned.