<div dir="ltr">Awesome, thanks! <br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, May 9, 2020 at 10:07 AM Dave Allured - NOAA Affiliate <<a href="mailto:dave.allured@noaa.gov">dave.allured@noaa.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>You can do this in a single run in an NCL program. Get a list of all the shapefile names. This can be done externally, or within NCL like this:</div><div><br></div><div> file_names = systemfunc ("ls -1 path/*.shp")</div><div><br></div><div>Then read all the precip data into a large array, one time only. Then loop over all the names of the shape files. For each shape file, use one of the known NCL methods to compute areal average over the defined region on the precip array. When the loop is finished, you will have one areal average for each region. </div><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, May 9, 2020 at 9:40 AM Xueyan Zhang via ncl-talk <<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hello ncl-talk,<div><br></div><div>I want to calculate areal average of precipitation (netcdf format) for hundreds of small regions that are defined by shapefiles with different names. Any ideas to do a batch work?</div><div><br></div><div>Thank you!</div><div><br></div><div>Xueyan</div></div></blockquote></div></div>
</blockquote></div>