<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Areal precipitation using IDW in Mapping Questions</title>
    <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391827#M4182</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Craig for your quick response. I figured out that I need to use ListField. I am struggling figuring out the correct syntax. I found a python script to iterate IDW on&lt;/SPAN&gt;&lt;A href="http://forums.esri.com/Thread.asp?c=93&amp;amp;f=1729&amp;amp;t=250879" rel="nofollow noopener noreferrer" target="_blank"&gt; ESRI Forum&lt;/A&gt;&lt;SPAN&gt; but that script was written for ArcGIS 9.3. I've recently upgraded to 10.2 and I think the scripts are now not compatible. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would be really grateful if you could provide further help. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;--kundan&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;The critical part you need to manipulate is the field names. Access to these can be achieved using:&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl= arcpy.ListFields(r'D:\Temp\Test.mdb\Test')
for fld_names in tbl:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print fld_names.name
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;or&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl = r'D:\Temp\Test.mdb\Test'
fld_names = [f.name for f in arcpy.ListFields(tbl)]
print fld_names
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;Second method many by more ideal for iterating in a script, as field names are stored in a python list/table.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Craig&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Dec 2021 17:57:28 GMT</pubDate>
    <dc:creator>KundanDhakal</dc:creator>
    <dc:date>2021-12-11T17:57:28Z</dc:date>
    <item>
      <title>Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391822#M4177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have got the following problem. I have a catchment and several gauging stations measuring daily precipitation amounts. I would like to interpolate the precipitation amounts from these stations (points) to the whole catchment. In the next step I would like to calculate average precipitation value for the catchment. I can do it for one day (1 value for each station).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem is that I have 30 years of daily precipitation measurements in each station and so I need to do this process thousands of times. I have created a simple model in model builder which could do this process once, but I am not able to force it to do it repeatedly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;I need help how to automate this process.&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Sep 2013 06:03:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391822#M4177</guid>
      <dc:creator>PV1</dc:creator>
      <dc:date>2013-09-09T06:03:10Z</dc:date>
    </item>
    <item>
      <title>IDW automation</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391823#M4178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have got the following problem. I have a catchment and several gauging stations measuring daily precipitation amounts. I would like to interpolate the precipitation amounts from these stations (points) to the whole catchment. In the next step I would like to calculate average precipitation value for the catchment. I can do it for one day (1 value for each station).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem is that I have 30 years of daily precipitation measurements in each station and so I need to do this process thousands of times. I have created a simple model in model builder which could do this process once, but I am not able to force it to do it repeatedly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;I need help how to automate this process.&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Sep 2013 06:04:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391823#M4178</guid>
      <dc:creator>PV1</dc:creator>
      <dc:date>2013-09-09T06:04:04Z</dc:date>
    </item>
    <item>
      <title>Re: Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391824#M4179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You will need to create a loop or iteration process to go through each or of your daily records. There are iteration tools in ModelBuilder or maybe export to python and code the iteration/loop process.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Craig&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Sep 2013 22:06:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391824#M4179</guid>
      <dc:creator>CPoynter</dc:creator>
      <dc:date>2013-09-09T22:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391825#M4180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;You will need to create a loop or iteration process to go through each or of your daily records. There are iteration tools in ModelBuilder or maybe export to python and code the iteration/loop process.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Craig&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Any example Craig that you would like to provide here? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am also stuck in same condition. Iteration in model builder does not clearly mention using fields within the same shapefile/ table (each field is a measurement for a day in my case). I think examples are not clear too. If I need to use IDW and iterate across multiple fields how would I set up the model builder? Attached is the screenshot of the attribute table of the shapefile I plant to iterate.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]27643[/ATTACH]&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Sep 2013 18:18:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391825#M4180</guid>
      <dc:creator>KundanDhakal</dc:creator>
      <dc:date>2013-09-20T18:18:15Z</dc:date>
    </item>
    <item>
      <title>Re: Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391826#M4181</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The critical part you need to manipulate is the field names. Access to these can be achieved using:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl= arcpy.ListFields(r'D:\Temp\Test.mdb\Test')
for fld_names in tbl:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print fld_names.name
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;or&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl = r'D:\Temp\Test.mdb\Test'
fld_names = [f.name for f in arcpy.ListFields(tbl)]
print fld_names
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Second method many by more ideal for iterating in a script, as field names are stored in a python list/table.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Craig&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 17:57:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391826#M4181</guid>
      <dc:creator>CPoynter</dc:creator>
      <dc:date>2021-12-11T17:57:26Z</dc:date>
    </item>
    <item>
      <title>Re: Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391827#M4182</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Craig for your quick response. I figured out that I need to use ListField. I am struggling figuring out the correct syntax. I found a python script to iterate IDW on&lt;/SPAN&gt;&lt;A href="http://forums.esri.com/Thread.asp?c=93&amp;amp;f=1729&amp;amp;t=250879" rel="nofollow noopener noreferrer" target="_blank"&gt; ESRI Forum&lt;/A&gt;&lt;SPAN&gt; but that script was written for ArcGIS 9.3. I've recently upgraded to 10.2 and I think the scripts are now not compatible. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would be really grateful if you could provide further help. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;--kundan&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;The critical part you need to manipulate is the field names. Access to these can be achieved using:&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl= arcpy.ListFields(r'D:\Temp\Test.mdb\Test')
for fld_names in tbl:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print fld_names.name
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;or&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
tbl = r'D:\Temp\Test.mdb\Test'
fld_names = [f.name for f in arcpy.ListFields(tbl)]
print fld_names
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;Second method many by more ideal for iterating in a script, as field names are stored in a python list/table.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Craig&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 17:57:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391827#M4182</guid>
      <dc:creator>KundanDhakal</dc:creator>
      <dc:date>2021-12-11T17:57:28Z</dc:date>
    </item>
    <item>
      <title>Re: Areal precipitation using IDW</title>
      <link>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391828#M4183</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Without testing it myself, try:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy
from arcpy import env
from arcpy.sa import *

arcpy.CheckOutExtension("Spatial")

env.workspace = 
srcFC =
cellSize =
power =
searchRadius = 

tbl= arcpy.ListFields(srcFC, 'r*')
for zField in tbl:
&amp;nbsp;&amp;nbsp;&amp;nbsp; print 'Processing: ' + zField

&amp;nbsp;&amp;nbsp;&amp;nbsp; outIDW = Idw(srcFC, zField, cellSize, power, searchRadius)
&amp;nbsp;&amp;nbsp;&amp;nbsp; outIDW.save(env.workspace + '\\' + zField + '_IDW')

del srcFC, cellSize, power, searchRadius, tbl, zField
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You will need to set your input workspace, source featureclass, cellsize, power, radius.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You will need to have a look at the 10.2 Help reference to IDW, so you can identify which Radius method you wish to utilise.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;What I have given here is a basis for development, which needs to be polished and finished to run for your application.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If it doesn't run in IDLE, run from within Python GUI in ArcGIS or ArcCatalog.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Craig&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 17:57:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/areal-precipitation-using-idw/m-p/391828#M4183</guid>
      <dc:creator>CPoynter</dc:creator>
      <dc:date>2021-12-11T17:57:31Z</dc:date>
    </item>
  </channel>
</rss>

