ploteries.figure_handler.table_handler¶
Functions
|
Classes
|
This object creates a table from one or more data series, with one row (or column when |
- class ploteries.figure_handler.table_handler.TableHandler(data_store, name: str, data_mappings: Tuple[str, SliceSequence] | Dict[str, Tuple[str, SliceSequence]], transposed: bool = False, data_table_template=None, columns_kwargs: Dict[str, dict] = {}, sorting='ascending', decoded_data_def=None)¶
This object creates a table from one or more data series, with one row (or column when
transposed=True) per time step, and the fields specified by data dictionaries derived from the data series. The simplest use case is to display data from aploteries.serializable_data_handler.SerializableDataHandlerdata series.The display uses the Dash DataTable class
dash_table.DataTable. Note: use classFigureHandlerto build Plotly Tables of typeplotly.graphic_objects.Table.In [1]: print('Hello world') Hello world In [2]:
- Parameters:
data_store – Source data store.
name – Name of the FigureHandler instance that will be used in the figure defs table.
data_mappings – A data series name /
jztools.slice_sequence.SSQ_-producible pair, or a dictionary of such pairs. In the first case, theSSQ_object is expected to produce a dictionary. In both cases, theSSQ_objects are applied to each record retrieved from the corresponding data series (i.e., to each entry ofdata_store['data_series_name']['data']), and the dictionary keys will be theidfor thecolumnsargument of thedash_table.DataStoreobject (as well as thenameby default, unless overwritten with argumentcolumns_kwargs).data_table_template – A
dash.dcc.DataTableor derived dictionary specifying the template used to build the data table.transposed – Whether to display the table in transposed form (where each record will appear as a column for the k-th time step).
sorting – Whether to display the data fields in ascending or descending order.
columns_kwargs – Dictionary mapping some or all
datakeys to extra kwargs to add to the correspondingdash_table.DataTablecolumnsargument (see DataTable reference).
- from_traces = None¶
- get_data_names()¶
Returns a list of all unique data names that this figure is dependent on.
- encode_params()¶
Produces the params field to place in the data_defs record.
- property is_indexed¶
Specifies whether the figure depends on a single time index.