Predefined nodes¶
Preparing data for plotting¶
Data Selection¶
To be written. Describe data selector, idea of compatible data.
Data Gridding¶
Converting data from a tabular format to a grid is done by the by the node class DataGridder
:
-
class
plottr.node.grid.
DataGridder
(name)¶ A node that can put data onto or off a grid. Has one property:
grid
. Its possible values are governed by a main option, plus (optional) additional options.-
property
grid
¶ Specification for how to grid the data. Consists of a main option and (optional) additional options.
The main option is of type
GridOption
, and the additional options are given as a dictionary. Assign as tuple, like:>>> dataGridder.grid = GridOption.<option>, dict((**options)
All types of
GridOption
are valid main options:GridOption.noGrid
–will leave tabular data as is, and flatten gridded data to result in tabular data
GridOption.guessShape
–use
guess_shape_from_datadict()
anddatadict_to_meshgrid()
to infer the grid, if the input data is tabular.
GridOption.specifyShape
–reshape the data using a specified shape.
GridOption.metadataShape
–use the shape specified in the dataset metadata
Some types may required additional options. At the moment, this is only the case for
GridOption.specifyShape
. Manual specification of the shape requires two additional options, order and shape:- order –
a list of the input data axis dimension names, in the internal order of the input data array. This order is used to transpose the data before re-shaping with the shape information. Often this is simply the axes list; then the transpose has no effect. A different order needed when the the data to be gridded is not in C order, i.e., when the axes order given in the DataDict is not from slowest changing to fastest changing.
- shape –
a tuple of integers that can be used to reshape the input data to obtain a grid. Must be in the same order as order to work correctly.
See
data.datadict.datadict_to_meshgrid()
for additional notes; order will be passed to inner_axis_order in that function, and shape to target_shape.- Return type
Tuple
[GridOption
,Dict
[str
,Any
]]
-
property
Data slicing and reduction to 1D or 2D¶
To be written.