Instructions
Image Percentage Clip Stretch is a method that applies linear stretching between specified minimum and maximum percentage pixel values. Pixels outside the specified percentage range are pushed to the maximum or minimum output pixel values.
For example, if most of the data is distributed between 20-100 and only a small portion is distributed at the extremes, we can use the percentage clip stretch method with a specified percentage of 2%. We find the grayscale values corresponding to the 2% and 98% percentages, and use these two values as the minimum and maximum values for the original image grayscale. Then we perform linear stretching. The values within the lowest 2% range are directly set to the minimum output value, and the values within the highest 2% range are directly set to the maximum output value. This adjusts the data between 20-100 to the range of 0-255, increasing the contrast of the image. The result returned is a raster dataset (RasterRDD).
For a description of image stretching, refer to the document Image Stretch.
Parameter Specification
Parameter Name | Default Value | Parameter Definition | Parameter Type |
---|---|---|---|
Input RDD | Input RasterRDD for analysis | RasterRDD | |
Minimum Clip Percentage (Optional) |
2.0 | Specifies the percentage location of the smallest portion to be clipped. Default is 2, meaning the lowest 2% values will be pushed to the minimum target pixel value. | Double |
Maximum Clip Percentage (Optional) |
98.0 | Specifies the percentage location of the largest portion to be clipped. Default is 98, meaning the highest 2% values will be pushed to the maximum target pixel value. | Double |
Minimum Target Pixel Value (Optional) |
0 | The minimum target pixel value. Original pixel values will be stretched between the minimum and maximum target pixel values. Default is 0. | Integer |
Maximum Output Pixel Value (Optional) |
255 | The maximum target pixel value. Original pixel values will be stretched between the minimum and maximum target pixel values. Default is 255. | Integer |