Replacing pixel/voxel value in images

From MIPAV
Jump to: navigation, search

You can replace the values of pixels or voxels in images by using the Replace pixel/voxel values command on the Utilities menu. Suppose, for example, that you have a set of images that contain not a number (NaN) values. To be able to use MIPAV algorithms on those images, you first need to replace those not a number values. The Replace pixel/voxel value command provides an easy way to replace those values or any pixel or voxel values.

To replace pixel or voxel value in images

1 Open the image whose pixels or voxels you want to change.
2 Select Utilities > Replace pixel/voxel values.
The Replace Pixel/Voxel Value dialog box (Figure 52) opens.

Replace Pixel or Voxel Value dialog box

Figure 52. Replace Pixel/Voxel Value dialog box
User-defined value
Specifies the value that you want to replace in the image.

ReplacePixelVoxelValueDialogBox.jpg

Presets
NaN-Not a number.
FieldvalueInfinity.jpg -Positive infinity.
FieldvalueNotInfinity.jpg -Negative infinity.
Replace with
Accept the default value or type another value.
New image
Shows in a new image window the image in which the value was replaced.
Replace image
Replaces the current image with the image in which the value was replaced.
OK
Applies the parameters that you specified to subsample the image.
Cancel
Disregards any changes you made in this dialog box, closes the dialog box, and does not subsample the image.
Help
Displays online help for this dialog box.

3 Do one of the following:

  • a Select User defined value and type the value that you want to replace in the text box
    <
  • b Select Presets and then select one of the following in the list box:
    • NaN -Not a number
    • FieldvalueInfinity.jpg-Positive infinity
    • FieldvalueNotInfinity.jpg -Negative infinity

4 Do one of the following:

  • Accept the default value in Replace with.
  • Type another value in the text box.

5 Select one of the following:

  • New image -To create a new image in its own image window using the replaced value
  • Replace image -To overwrite the original image in the original image window with an image using the replaced value

6 Click OK. The image with the replaced value appears in either a new window or in the original image window.

See also:

Rotating images

Changing Image Datasets Using MIPAV Utilities