TH - Threshold - Set pixels above/below Threshold to Threshold

(10/09/07)

PURPOSE

Replaces all values within an image or volume beyond a specified threshold by the threshold value(s). Operation works for both 2-D and 3-D images.   Example.

SEE ALSO

TH F [Threshold - Set pixels above/below Threshold to Fixed value]
TH M [Threshold - Create Mask based on Threshold]

USAGE

.OPERATION: TH
<or>
TH [num]

.INPUT FILE: TST001
[Enter the name of the input file.]

.OUTPUT FILE: TST002
[Enter the name of the output file.]

.ALTER (A)BOVE THRESHOLD, (B)ELOW, OR (C) BOTH SIDES (A/B/C): A
[Option 'A' : Replaces all values greater than the specified threshold with the threshold value.
Option 'B' : Replaces all values smaller than the specified threshold with the threshold value.
Option 'C' : Replaces all values smaller than the lower threshold with the lower threshold value and all values greater than the upper threshold with the upper threshold value.

For options 'A' and 'B' , SPIDER asks:

.THRESHOLD: 1.2
[Enter the threshold value desired.]

For option 'C' , SPIDER asks:

.UPPER, LOWER THRESHOLD: 1.2, 0.8
[Enter two thresholds between which the original image data are to be preserved.]

NOTES

  1. Optional output register variable (if given on operation line) will receives number of altered pixels/voxels.

SUBROUTINES

THRESH

CALLER

UTIL2

© Copyright Notice /       Enquiries: spider@wadsworth.org