SubImageStatistics

MLModule
genre Statistics
status stable
author Uwe Siems
package MeVisLab/Standard
dll MLMiscModules
definition MLMiscModules.def
see also ImageStatistics
keywords image, average, mean, absolute, standard, deviation, minimum, maximum, statistic, weight, interval, voxels, count

Purpose

The module SubImageStatistics computes some statistics of the input image voxels.

Statistics are calculated along the dimensions the user selected. Default is computation along the X, Y and Z axis. The results are returned in the output image where the first dimension along which statistics were computed contains the various statistical values, all other reduced dimensions are one and the remaining dimensions are unchanged. Which values are returned can be controlled through the emit... fields.

A subset of voxels can be selected by providing an interval of grey values. Voxels with values outside this interval are ignored if this feature is activated.

A subset can also be defined by providing a mask image at the second input to this module. Voxels will only be considered if the mask image at this place contains a non-zero value (if the image has an integer type) or greater than zero (if the image has a floating point type).

The mask does not need to have the same size as the data image, everything outside the mask image area is treated as if the mask was zero. But a special handling occurs if the mask has size one in any direction: In this case, the mask is replicated along these axes to infinity.

If you do not want this behavior, bring the mask image size to the data image size with an SubImage module before connecting it to SubImageStatistics (or at least to size 2 in the affected dimension).

There is a read-only field that indicates if a valid image mask is connected to the second input. If this field is unchecked, the mask is not considered even if an image is connected (e.g. because it is invalid).

If both an mask image and a grey value interval is specified, both are combined, i.e. only voxels where the mask is set and whose grey values lie inside the interval are considered.

Windows

Default Panel

../../../Modules/ML/MLMiscModules/mhelp/Images/Screenshots/SubImageStatistics._default.png

Input Fields

input0

name: input0, type: Image

input1

name: input1, type: Image

Output Fields

output0

name: output0, type: Image

Parameter Fields

Visible Fields

Minimum voxel value

name: minValue, type: Double, default: -1000

Sets the lower interval bound.

Maximum voxel value

name: maxValue, type: Double, default: 1000

Sets the upper interval bound.

Only consider voxels in interval

name: useInterval, type: Bool, default: FALSE

If checked, only voxel with a value in the interval specified by Minimum voxel value and Maximum voxel value are investigated.

Fold X Axis

name: foldXDim, type: Bool, default: TRUE

If checked, the statistics are applied along the x-axis.

Fold Y Axis

name: foldYDim, type: Bool, default: TRUE

If checked, the statistics are applied along the y-axis.

Fold Z Axis

name: foldZDim, type: Bool, default: TRUE

If checked, the statistics are applied along the z-axis.

Fold C Axis

name: foldCDim, type: Bool, default: FALSE

If checked, the statistics are applied along the c-axis.

Fold T Axis

name: foldTDim, type: Bool, default: FALSE

If checked, the statistics are applied along the t-axis.

Fold U Axis

name: foldUDim, type: Bool, default: FALSE

If checked, the statistics are applied along the u-axis.

Emit Average

name: emitAverage, type: Bool, default: TRUE

If checked, the average value is set to the first dimension of the output image.

Emit Std.Dev.

name: emitStdDev, type: Bool, default: TRUE

If checked, the standard deviation is set to the second dimension of the output image.

Emit Minimum

name: emitMinimum, type: Bool, default: TRUE

If checked, the minimum value is set to the third dimension of the output image.

Emit Maximum

name: emitMaximum, type: Bool, default: TRUE

If checked, the maximum value is set to the fourth dimension of the output image.

Emit Voxel Count

name: emitCount, type: Bool, default: TRUE

If checked, the number of voxels is set to the fifth dimension of the output image.

Mask Image is valid and used

name: maskIsValid, type: Bool, persistent: no

Shows if the attached mask image is valid and used.

Auto apply

name: autoApply, type: Bool, default: TRUE

If checked, the module updates the output image on any parameter or input image change.

Apply

name: apply, type: Trigger

If pressed, the module updates its output image.