Use Class Statistics compute statistics on a raster.

You can also write a script to compute statistics using the ClassificationStatistics task.

  1. From the Toolbox, select Classification > Post Classification > Class Statistics. The Class Statistics dialog appears.
  2. Select an Input Raster to use for statistics generation. Perform any optional spatial subsetting, then click OK.
  3. Select an Input Classification Raster to use for statistics generation. Perform any optional spatial subsetting, then click OK.
  4. Specify a Classes. This field represents the structuring element used to expand shapes contained in the input image. An array size of 3x3 and element values of 1 are used unless otherwise specified.
  5. For Compute Covariance, select Yes if you want to to compute covariance matrix, eigenvectors, eigenvalues, and correlation.
  6. For Compute Histograms, select Yes if you want to to compute histograms.
  7. Use Output Report URI to specify an output path and filename for the text file that will contain the statistics.
  8. Enable the Display result check box to display the output in the view when processing is complete. Otherwise, if the check box is disabled, the result can be loaded from the Data Manager.
  9. To reuse these task settings in future ENVI sessions, save them to a file. Click the down arrow next to the OK button , select Save Parameter Values, then specify the path and filename to save to. Note that some parameter types, such as rasters, vectors, and ROIs, will not be saved with the file. To apply the saved task settings, click the down arrow and select Restore Parameter Values, then select the file where you previously saved your settings.

  10. You can run the process in the background on your computer or in the background on an ENVI Server (if available). Click the down arrow next to the OK button and select one of the following:

    • Run Task in the Background: Runs the process on your computer. This method does not use an ENVI Server. The job progress will show in the ENVI Job Console's Background Jobs tab.
    • Run Task on envi_server_name. Runs the process on the selected ENVI Server. The job progress will show in the ENVI Job Console's envi_server_name tab.

    See ENVI Job Console for details on monitoring ENVI Server jobs and viewing results. See ENVI Servers for details on configuring and using an ENVI Server.

  11. Click OK.