NDSlicer#

NDSlicer#

Constructor#

NDSlicer(data, dims, display_dims[, ...])

Base class for managing n-dimensional data and producing array slices.

Properties#

NDSlicer.data

get or set managed data.

NDSlicer.dims

dim names, ordered as laid out in the array

NDSlicer.display_dims

Subset of dims that are spatial (rendered) dimensions in display order.

NDSlicer.display_dims_indices

The ordered spatial dim indices that correspond to the named spatial dims

NDSlicer.n_slider_dims

number of slider dims, i.e. len(slider_dims).

NDSlicer.ndim

number of dims

NDSlicer.shape

interpreted shape of the data

NDSlicer.slider_dims

Slider dim names, set(dims) - set(display_dims), unordered

NDSlicer.slider_maps

Get or set the per-slider-dim mapping from reference-space values to local array indices, {dim_name: transform}.

NDSlicer.spatial_func

Get or set the spatial function which is applied on the data slice after the window functions.

NDSlicer.tooltip

whether or not a custom tooltip formatter method exists

NDSlicer.window_funcs

Get or set the per-slider-dim window functions applied around the current slider position, {dim_name: (func, window_size)}, ex: {"time": (np.mean, 2.5)}.

NDSlicer.window_order

get or set dimension order in which window functions are applied

Methods#

NDSlicer.close()

Shut down the thread pool.

NDSlicer.get(indices)

Get the data slice to display at the given indices.

NDSlicer.get_window_output(indices)

Take the data slice at the given indices and apply the window functions.

NDSlicer.tooltip_format(*args)

Override in subclass to format custom tooltips