nipy.labs.datasets.volumes.volume_field.VolumeField.values_in_world

VolumeField.values_in_world(x, y, z, interpolation=None)

Return the values of the data at the world-space positions given by x, y, z

Parameters
xnumber or ndarray

x positions in world space, in other words milimeters

ynumber or ndarray

y positions in world space, in other words milimeters. The shape of y should match the shape of x

znumber or ndarray

z positions in world space, in other words milimeters. The shape of z should match the shape of x

interpolationNone, ‘continuous’ or ‘nearest’, optional

Interpolation type used when calculating values in different word spaces. If None, the image’s interpolation logic is used.

Returns
valuesnumber or ndarray

Data values interpolated at the given world position. This is a number or an ndarray, depending on the shape of the input coordinate.