Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have multiple rasters and feature classes that I want to clip to a study area.

I am pretty new to ModelBuilder.

I know you can right click the clip tool to batch clip outside of ModelBuilder but how do I bring that into ModelBuilder at ArcGIS 10.1 for Desktop?

share|improve this question

2 Answers 2

up vote 6 down vote accepted

ModelBuilder functions differently than batch processing in ArcGIS. Typically, you use iterators to loop through individual files rather than a spreadsheet-type list of files and actions, as in batch mode. The following is an example of the type of model you would need to loop through a workspace containing rasters in order to clip them to study area bound. For clipping FC's simply replace "iterate rasters" with "iterate features" and change the clip raster tool to clip (analysis).

Additional Resources:

enter image description here

share|improve this answer
1  
some background info: quick tour of iterators and examples of iterators. –  Roland Jan 31 at 18:10
    
Thanks @Roland--these have been incorporated into the answer. –  Aaron Jan 31 at 18:23

I eventually created a tool at work to do this and thought I would share it if anyone is interested. It is pretty simple as I am not a programmer. The script will make a list of all rasters in the input workspace and clip them to an input feature class. Each output raster will be named the same as the original raster plus "_Clip".

import arcpy
#Set variables
wspace = arcpy.GetParameterAsText (0)
clip_feature = arcpy.GetParameterAsText (1)

#Set user input workspace (Geodatabase containing rasters)
#and output cell size
arcpy.env.workspace = wspace
arcpy.env.cellSize = 30

#List rasters in the workspace and clip them to the user input feature class boundary
rlist = arcpy.ListRasters ()
print rlist

#The output name will be the input raster name followed with "_Clip"
name = "Clip"
for rast in rlist:
arcpy.Clip_management (rast, "#", rast + "_" + str (name), clip_feature, "", "ClippingGeometry")

This could be brought into model builder if required as another solution to my own question.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.