Column.from_vector
Column.from_vectorname items value_type
Group: Input
Documentation
Creates a new column given a name and a vector of elements.
Arguments
name
: The name of the column to create.items
: The elements to contain in the column.value_type
: The type of the values in the column. IfAuto
, the type will be inferred from the items in the column.
Examples
Create a new column called "My Column" from a vector of numbers.
from Standard.Table import Column
example_from_vector =
Column.from_vector "My Column" [1, 2, 3, 4, 5]
Errors
- If some values in
items
do not match thevalue_type
, anInvalid_Value_Type
error is raised. - With the default
value_type
ofAuto
, no errors should occur.