Official websites use .gov
A .gov website belongs to an official government organization in the United States.

Secure .gov websites use HTTPS
A lock ( ) or https:// means you’ve safely connected to the .gov website. Share sensitive information only on official, secure websites.

ISIS Documentation

percent

Obtains the DN value at a percent in a histogram

This program will output the DN value at a cumulative percentage in a histogram. For example, requesting the 50% DN will output the median. Values such as the 0.5% and 99.5% are good for selecting minimums and maximums which do not include outliers. The histogram will be obtained from a single band in the input cube and is identified using the band specifier (e.g., file.cub:5). In general, this program is used within batch jobs, perl programs, or other scripting languages. The value(s) will be written to the output text file specified by the parameter TO and it can be extracted using the "getkey" program. If multiple percents were requested, the values are printed to the text file in the same order as the requested percents and are comma delimited.

Categories


Related Objects and Documents

Applications


History

Jeff Anderson2002-10-25 Original version
K Teal Thompson2002-11-25 Add example
K Teal Thompson2003-03-28 Make images smaller.
Stuart Sides2003-04-04 Fixed problem with isiscvs not checking in the thumb and image directories.
Kim Sides2003-05-13 Added application test
Stuart Sides2003-05-16 Modified schema location from astogeology... to isis.astrogeology..."
Jeff Anderson2003-06-03 Updated application test due to compiler optimizations
Stuart Sides2003-07-29 Modified filename parameters to be cube parameters where necessary
Jeff Anderson2003-08-27 Change default extension handling mechanism
Stuart Sides2003-11-07 Modified results pvl to not include the results group
Jacob Danton2006-01-23 Fixed appTest to comply to changes in String
Steven Lambright2008-05-13 Removed references to CubeInfo

Parameters

Files

Compute the histogram using this cube file. The program operates on only one band and therefore a band specifier is required (e.g., file.cub:3)
Type cube
File Mode input
Filter *.cub

A text file in label format which will contain the results of this program. This file can be used inconjunction with the "getkey" program in order to pass the results to another program.
Type filename
File Mode output
Internal Default None

Selection

This parameter indicates the cumulative percentage to examine in the histogram. The DN value at that percentage will be output by this program. For example, PERCENTAGE=50 will return the median of the image. When entering multiple percentages, be sure they are comma delimited.
Type string
Minimum 0.0 (exclusive)
Maximum 100.0 (exclusive)

Example 1

percent.txt

Use text file output

Command Line

Set TO parameter to percent.txt
percent f=../IN/f332s28.cub t=OUT/percent.txt p=50

GUI Screenshot

percent GUI

Example GUI

percent GUI

Screenshot of GUI with parameters filled in to perform the percent operation

Input Image

Input image

Input image for percent

Input image

Parameter Name: FROM

This is the input image f332s28.cub

Output Images

This is the text file percent.txt.

Output text file

This is the text file percent.txt.

Parameter Name: TO

Output text file shown in editor giving results of the percent application.

This is the text file multiple-percents.txt.

This is the text file multiple-percents.txt.

Results of the percent application when multiple percentages are requested.