One, Arcengle value assignment
There are no intrinsic functions found in the engine and can only be handled with GP tools.
<summary>
Null value processing Author:allenrobin http://gisrsman.cnblogs.com
</summary>
Private Static voidNull2number (Igeodataset Praster,stringoutpath,double number) { //Check out empty location (NULL location 1, non-null zone is 0) stringIsnullpath = System.IO.Path.Combine (Application.startuppath,"isnull.tif"); Geoprocessor GP=NewGeoprocessor ();//Initialize GeoprocessorGp. Overwriteoutput =true;//allow the result of an operation to overwrite an existing fileESRI. ArcGIS.SpatialAnalystTools.IsNull ISNULLGP =NewESRI. ArcGIS.SpatialAnalystTools.IsNull (); Isnullgp.in_raster=Praster; Isnullgp.out_raster=Isnullpath; Gp. Execute (ISNULLGP,NULL); //Set the empty (that is, 1) to 0 and the rest to the original valueGeoprocessor GP1 =Newgeoprocessor (); Gp1. Overwriteoutput=true; ESRI. ArcGIS.SpatialAnalystTools.Con CONGP=NewESRI. ArcGIS.SpatialAnalystTools.Con (); Congp.in_conditional_raster=Isnullpath; Congp.out_raster=Outpath; Congp.where_clause="Value = 1";//The place where the value=1 is the null to be queried .Congp.in_false_raster_or_constant =Praster; Congp.in_true_raster_or_constant=number;//change NULL to 0 or another value
Gp1. Execute (CONGP,NULL);
}
Second, the ArcGIS raster data null value processing
Refer to Handling in ArcMap
---------------------------------------------------------------------------------
When two rasters are superimposed, sometimes there is no data, value is nodata,nodata+ any number =nodata, so when you need to assign values to the raster null values, the conditional query function is used to assign the place of NoData.
1. Null value (Nodata) Assignment:
In the raster calculator, enter the function expression CON (ISNULL ([raster]), 0,[raster]). Where [raster] is the input raster name. A raster image is automatically generated with an external rectangle of the input raster image, where the grid value is not empty and where NoData is 0.
2. A specific value is converted to a null value
Use the function expression SetNull to assign a value of a specific raster value to a null value.
SetNull ([Raster==1],[raster]), the data in the raster value of 1 is empty, and the other retains the original value.
Citation: ArcGIS Raster data null processing
Arcengle the processing of a hollow value (Null \ Nodata) value