Table#
- class Table(*args, **kwargs)[source]#
Wrapper for the vtkTable class.
Create by passing a 2D NumPy array of shape (
n_rowsbyn_columns) or from a dictionary containing NumPy arrays.- Parameters:
- *argsvtkTable,
numpy.ndarray,dict,pandas.DataFrame,optional Data source used to initialize the table.
- deepbool, default:
True Deep copy the input when initializing from a vtkTable.
- **kwargs
dict,optional Unused.
Deprecated since version 0.49: These arguments have never had any effect and will be removed.
- *argsvtkTable,
Examples#
Download Python source code | Download Jupyter notebook
>>> import pyvista as pv
>>> import numpy as np
>>> arrays = np.random.default_rng().random((100, 3))
>>> table = pv.Table(arrays)
Used In#
Docstring Examples
Table.is_empty(1 use)Table.to_arrow(1 use)
Inheritance#
Inherited members are documented on DataObject.
See them all under Inherited Attributes and Inherited Methods.
Wraps vtkTable.
Attributes#
Return |
|
Return the number of columns. |
|
Return the number of columns. |
|
Return the number of rows. |
|
Return the all row arrays. |
Inherited Attributes#
Return the actual size of the dataset object. |
|
Return FieldData as DataSetAttributes. |
|
Get address of the underlying VTK C++ object. |
|
Set or return a user-specified data dictionary. |
Methods#
|
Get an array by its name. |
|
Get the min and max of a named array. |
Return the table items. |
|
Return the table keys. |
|
|
Pop off an array by the specified name. |
|
Save the table. |
Return this table as a |
|
Create a Pandas DataFrame from this Table. |
|
|
Set the table data using a dict-like update. |
Return the table values. |
Inherited Methods#
Add field data. |
|
Convert this |
|
Remove all field data. |
|
Return a copy of the object. |
|
Copy the data attributes of the input dataset object. |
|
Copy pyvista meta data onto this object from another object. |
|
Copy the structure (geometry and topology) of the input dataset object. |
|
Overwrite this data object with another data object as a deep copy. |
|
Return the header stats of this dataset. |
|
Shallow copy the given mesh to this mesh. |