class WrightTools.data.Data(*args, **kwargs)[source]

Bases: WrightTools._group.Group

Multidimensional dataset.

__init__(*args, **kwargs)[source]

Create a new Group object by binding to a low-level GroupID.


bring_to_front(channel) Bring a specific channel to the zero-indexed position in channels.
chop(*args[, at, parent, verbose]) Divide the dataset into its lower-dimensionality components.
close() Close the file that contains the Group.
collapse(axis[, method]) Collapse the dataset along one axis, adding lower rank channels.
convert(destination_units, *[, …]) Convert all compatable axes and constants to given units.
copy([parent, name, verbose]) Create a copy under parent.
create_channel(name[, values, shape, units, …]) Append a new channel.
create_constant(expression, *[, verbose]) Append a constant to the stored list.
create_dataset(name[, shape, dtype, data]) Create a new HDF5 dataset
create_group(name[, track_order]) Create and return a new subgroup.
create_variable(name[, values, shape, …]) Add new child variable.
downscale(tup[, name, parent]) Down sample the data array using local averaging.
flush() Ensure contents are written to file.
get(name[, default, getclass, getlink]) Retrieve an item or other information.
get_nadir([channel]) Get the coordinates, in units, of the minimum in a channel.
get_zenith([channel]) Get the coordinates, in units, of the maximum in a channel.
gradient(axis, *[, channel]) Compute the gradient along one axis.
heal([channel, method, fill_value, verbose]) Remove nans from channel using interpolation.
level(channel, axis, npts, *[, verbose]) Subtract the average value of npts at the edge of a given axis.
map_variable(variable, points[, …]) Map points of an axis to new points using linear interpolation.
moment(axis[, channel, moment]) Take the nth moment the dataset along one axis, adding lower rank channels.
offset(points, offsets, along, offset_axis) Offset one axis based on another axis’ values.
print_tree(*[, verbose]) Print a ascii-formatted tree representation of the data contents.
prune([keep_channels, verbose]) Remove unused variables and (optionally) channels from the Data object.
remove_channel(channel, *[, verbose]) Remove channel from data.
remove_constant(constant, *[, verbose]) Remove a constant from the stored list.
remove_variable(variable, *[, implied, verbose]) Remove variable from data.
rename_channels(*[, verbose]) Rename a set of channels.
rename_variables(*[, implied, verbose]) Rename a set of variables.
save([filepath, overwrite, verbose]) Save as root of a new file.
set_constants(*constants[, verbose]) Set the constants associated with the data.
share_nans() Share not-a-numbers between all channels.
smooth(factors[, channel, verbose]) Smooth a channel using an n-dimenional kaiser window.
split(expression, positions, *[, units, …]) Split the data object along a given expression, in units.
transform(*axes[, verbose]) Transform the data.
update([E, ]**F) If E present and has a .keys() method, does: for k in E: D[k] = E[k] If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v In either case, this is followed by: for k, v in F.items(): D[k] = v
zoom(factor[, order, verbose]) Zoom the data array using spline interpolation of the requested order.


attrs Attributes attached to this object
axis_expressions Axis expressions.
axis_names Axis names.
channel_names Channel names.
channels Channels.
constant_expressions Axis expressions.
constant_names Axis names.
constant_units All constant units.
datasets Datasets.
file Return a File instance associated with this object
fullpath file and internal structure.
id Low-level identifier appropriate for this object
item_names Item names.
kind Kind.
name Return the full name of this object.
natural_name Natural name.
ndim Get number of dimensions.
parent Parent.
ref An (opaque) HDF5 reference to this object
regionref Create a region reference (Datasets only).
shape Shape.
size Size.
source Source.
units All axis units.
variable_names Variable names.
variables Variables.