Tables are collections of Vectors and have a Schema. Use the convenience methods makeTable or tableFromArrays to create a table in JavaScript. To create a table from the IPC format, use tableFromIPC.

Type Parameters

  • T extends TypeMap = any

Constructors

  • Type Parameters

    • T extends TypeMap = any

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • batches: Iterable<RecordBatch<T>>

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • Rest ...batches: readonly RecordBatch<T>[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • Rest ...columns: {
          [P in string | number | symbol]: Vector<T[P]>
      }[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • Rest ...columns: {
          [P in string | number | symbol]: Data<T[P]> | DataProps<T[P]>
      }[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • schema: Schema<T>
    • Rest ...columns: {
          [P in string | number | symbol]: Vector<T[P]>
      }[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • schema: Schema<T>
    • Rest ...columns: {
          [P in string | number | symbol]: Data<T[P]> | DataProps<T[P]>
      }[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • schema: Schema<T>
    • Optional data: RecordBatch<T> | RecordBatch<T>[]

    Returns Table<T>

  • Type Parameters

    • T extends TypeMap = any

    Parameters

    • schema: Schema<T>
    • Optional data: RecordBatch<T> | RecordBatch<T>[]
    • Optional offsets: Uint32Array

    Returns Table<T>

Properties

TArray: StructRowProxy<T>[]
TType: Struct<T>
TValue: StructRowProxy<T>
[isConcatSpreadable]: true
batches: RecordBatch<T>[]

The contiguous RecordBatch RecordBatch chunks of the Table rows.

schema: Schema<T>

Accessors

  • get data(): Data<Struct<T>>[]
  • The contiguous RecordBatch RecordBatch chunks of the Table rows.

    Returns Data<Struct<T>>[]

  • get nullCount(): number
  • The number of null rows in this Table.

    Returns number

  • get numCols(): number
  • The number of columns in this Table.

    Returns number

  • get numRows(): number
  • The number of rows in this Table.

    Returns number

Methods

  • Iterator for rows in this Table.

    Returns IterableIterator<any>

  • Type Parameters

    • R extends TypeMap = any

    Parameters

    Returns Table<T & R>

  • Get an element value by position.

    Parameters

    • index: number

      The index of the element to read. A negative index will count back from the last element.

    Returns null | StructRowProxy<T>

  • Combines two or more Tables of the same schema.

    Parameters

    • Rest ...others: Table<T>[]

      Additional Tables to add to the end of this Tables.

    Returns Table<T>

  • Get an element value by position.

    Parameters

    • index: number

      The index of the element to read.

    Returns null | StructRowProxy<T>

  • Returns a child Vector by name, or null if this Vector has no child with the given name.

    Type Parameters

    • P extends string | number | symbol

    Parameters

    • name: P

      The name of the child to retrieve.

    Returns null | Vector<T[P]>

  • Returns a child Vector by index, or null if this Vector has no child at the supplied index.

    Type Parameters

    Parameters

    • index: number

      The index of the child to retrieve.

    Returns null | Vector<R>

  • Retrieve the index of the first occurrence of a value in an Vector.

    Parameters

    • element: StructRowProxy<T>

      The value to locate in the Vector.

    • Optional offset: number

      The index at which to begin the search. If offset is omitted, the search starts at index 0.

    Returns number

  • Check whether an element is null.

    Parameters

    • index: number

      The index at which to read the validity bitmap.

    Returns boolean

  • Construct a new Table containing only specified columns.

    Type Parameters

    • K extends string | number | symbol = any

    Parameters

    • columnNames: K[]

      Names of columns to keep.

    Returns Table<{
        [key: string]: K;
    }>

    A new Table of columns matching the specified names.

  • Construct a new Table containing only columns at the specified indices.

    Type Parameters

    Parameters

    • columnIndices: number[]

      Indices of columns to keep.

    Returns Table<{
        [key: string]: K;
    }>

    A new Table of columns at the specified indices.

  • Set an element value by position.

    Parameters

    • index: number

      The index of the element to write.

    • value: null | StructRowProxy<T>

      The value to set.

    Returns void

  • Sets a child Vector by name.

    Type Parameters

    • P extends string | number | symbol
    • R extends DataType<Type, any>

    Parameters

    • name: P

      The name of the child to overwrite.

    • child: Vector<R>

    Returns Table<T & {
        [K in string | number | symbol]: R
    }>

    A new Table with the supplied child for the specified name.

  • Sets a child Vector by index.

    Parameters

    • index: number

      The index of the child to overwrite.

    • Optional child: null

    Returns Table<any>

    A new Table with the supplied child at the specified index.

  • Type Parameters

    Parameters

    Returns Table<any>

  • Return a zero-copy sub-section of this Table.

    Parameters

    • Optional begin: number

      The beginning of the specified portion of the Table.

    • Optional end: number

      The end of the specified portion of the Table. This is exclusive of the element at the index 'end'.

    Returns Table<T>

  • Return a JavaScript Array of the Table rows.

    Returns any[]

    An Array of Table rows.

  • Returns a string representation of the Table rows.

    Returns string

    A string representation of the Table rows.