Show Navigation | Hide Navigation
You are here:
Geoprocessing tool reference > Data Management toolbox > Data Comparison toolset > Tools

Raster Compare (Data Management)

Release 9.2
Last modified November 29, 2010
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Tools"


Related Topics

Compares the properties of two rasters datasets or two raster catalogs and returns the comparison result.


Usage tips

Command line syntax
An overview of the Command Line window
RasterCompare_management <in_base_raster> <in_test_raster> <Raster Dataset | GDB Raster Dataset | GDB Raster Catalog> {ignore_option;ignore_option...} {NO_CONTINUE_COMPARE | CONTINUE_COMPARE} {out_compare_file}

Parameter Explanation Data Type
<in_base_raster>

The raster dataset that will be compared to the test raster.

Raster Layer | Raster Catalog Layer
<in_test_raster>

The raster dataset that will be compared to the input base raster.

Raster Layer | Raster Catalog Layer
<Raster Dataset | GDB Raster Dataset | GDB Raster Catalog>

The type of comparison.

  • Raster Dataset — Compares raster dataset properties.
  • GDB Raster Dataset — Compares properties of rasters datasets in a geodatabase.
  • GDB Raster Catalog — Compares properties of raster catalogs in a geodatabase.

String
{ignore_option;ignore_option...}

The properties specified will not be compared during comparison.

String
{NO_CONTINUE_COMPARE | CONTINUE_COMPARE}

Indicates whether to compare all properties after encountering the first mismatch.

  • NO_CONTINUE_COMPARE — Stop after encountering the first mismatch. This is the default.
  • CONTINUE_COMPARE — Compare other properties after encountering the first mismatch.

Boolean
{out_compare_file}

The name and path of the text file which will contain the comparison results.

Text File
Data types for geoprocessing tool parameters


Command line example

RasterCompare_management C:\basedata\redlands.img C:\testdata\redlands.tif 'Raster Dataset' # CONTINUE_COMPARE C:\tempdata\compare.txt

Scripting syntax
About getting started with writing geoprocessing scripts
RasterCompare_management (in_base_raster, in_test_raster, compare_type, ignore_option, continue_compare, out_compare_file)

Parameter Explanation Data Type
in_base_raster (Required)

The raster dataset that will be compared to the test raster.

Raster Layer | Raster Catalog Layer
in_test_raster (Required)

The raster dataset that will be compared to the input base raster.

Raster Layer | Raster Catalog Layer
compare_type (Required)

The type of comparison.

  • Raster Dataset — Compares raster dataset properties.
  • GDB Raster Dataset — Compares properties of rasters datasets in a geodatabase.
  • GDB Raster Catalog — Compares properties of raster catalogs in a geodatabase.

String
ignore_option (Optional)

The properties specified will not be compared during comparison.

String
continue_compare (Optional)

Indicates whether to compare all properties after encountering the first mismatch.

  • NO_CONTINUE_COMPARE — Stop after encountering the first mismatch. This is the default.
  • CONTINUE_COMPARE — Compare other properties after encountering the first mismatch.

Boolean
out_compare_file (Optional)

The name and path of the text file which will contain the comparison results.

Text File

Data types for geoprocessing tool parameters


Script example

Import arcgisscripting
gp=arcgisscripting.create()

gp.RasterCompare ( €˜
c:\basedata\redlands.img €™
, €™
c:\testdata\redlands.tif €™
, €™
Raster Dataset €™
, €™
# €™
, €™
CONTINUE_COMPARE €™
, €™
c:\temp\compare.txt €™
)

Please visit the Feedback page to comment or give suggestions on ArcGIS Desktop Help.
Copyright © Environmental Systems Research Institute, Inc.