Show Navigation | Hide Navigation
You are here:
Extensions > Spatial Analyst > Spatial Analyst functional reference > Reclass (Spatial Analyst)

Reclassify

Release 9.3
Last modified September 7, 2011
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Reclass (Spatial Analyst)"


Related Topics

Reclassifies (or changes) the values in a raster.


Usage tips

Command line syntax
An overview of the Command Line window
Reclassify_sa <in_raster> <reclass_field> <remap> <out_raster> {DATA | NODATA}

Parameter Explanation Data Type
<in_raster>

Input raster to be reclassified.

Composite Geodataset
<reclass_field>

Field denoting the values that will be reclassified.

Field
<remap>

A remap list that defines how the values will be reclassified.

The remap list is composed of three components: From, To, and New values. Each row in the remap list is separated by a semicolon, and the three components are separated by spaces. For example, "0 5 1;5.01 7.5 2;7.5 10 3".

Remap
<out_raster>

The raster to be created.

Raster Dataset
{DATA | NODATA}

Denotes whether missing values in the reclass table retain their value or get mapped to NoData.

  • DATA  — A keyword signifying that if any cell location on the input raster contains a value that is not present or reclassed in a remap table, the value should remain intact and be written for that location to the output raster.
  • NODATA  — A keyword signifying that if any cell location on the input raster contains a value that is not present or reclassed in a remap table, the value will be reclassed to NoData for that location on the output raster.

Boolean
Data types for geoprocessing tool parameters


Command line example

Reclassify_sa c:/data/ras_1 Value "0.000000 30.000000 1;31.000000 270.000000 2;271.000000 365.000000 3" c:/data/final_1 DATA

Scripting syntax
About getting started with writing geoprocessing scripts
Reclassify_sa (in_raster, reclass_field, remap, out_raster, missing_values)

Parameter Explanation Data Type
in_raster (Required)

Input raster to be reclassified.

Composite Geodataset
reclass_field (Required)

Field denoting the values that will be reclassified.

Field
remap (Required)

A remap list that defines how the values will be reclassified.

The remap list is composed of three components: From, To, and New values. Each row in the remap list is separated by a semicolon, and the three components are separated by spaces. For example, "0 5 1;5.01 7.5 2;7.5 10 3".

Remap
out_raster (Required)

The raster to be created.

Raster Dataset
missing_values (Optional)

Denotes whether missing values in the reclass table retain their value or get mapped to NoData.

  • DATA  — A keyword signifying that if any cell location on the input raster contains a value that is not present or reclassed in a remap table, the value should remain intact and be written for that location to the output raster.
  • NODATA  — A keyword signifying that if any cell location on the input raster contains a value that is not present or reclassed in a remap table, the value will be reclassed to NoData for that location on the output raster.

Boolean

Data types for geoprocessing tool parameters


Script example

# Reclassify.py
# Description:
#   Reclassifies (or changes) the values in a raster on a 
#   cell-by-cell basis within the analysis window.
# Requirements: None
# Author: ESRI
# Date: Sept 6, 2005
# Import system modules
import arcgisscripting

# Create the Geoprocessor object
gp = arcgisscripting.create()

try:
    # Set the input files
    inRaster = "c:/data/ras_1"

    # Set the output raster name
    outRaster = "c:/data/final_1"

    # Check out ArcGIS Spatial Analyst extension license
    gp.CheckOutExtension("Spatial")

    # Set the reclassify ranges
    reclassifyRanges = "0.000000 30.000000 1;31.000000 270.000000 2;271.000000 365.000000 3"

    # Process: Reclassify
    gp.Reclassify_sa(inRaster, "Value", reclassifyRanges, outRaster, "DATA")

except:
    # If an error occurred while running a tool, then print the messages
    print gp.GetMessages()

Map Algebra syntax
Not available

ArcObjects syntax
See ReclassByRemap

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