<?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 automated polygon movement? in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236104#M18361</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am trying to write a script that takes a single polygon shapefile ( a facility footprint), a grid of planning units, and a landcover shapefile, and, for each planning unit gridcell, shifts the geographic location of the footprint shapefile, and uses the newly located footprint to erase the underlying landcover. What's the best way to iterate through the cells, and aligns the footprint shapefile with the center of the gridcell? Thanks...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 18 Sep 2012 19:44:49 GMT</pubDate>
    <dc:creator>leifolson</dc:creator>
    <dc:date>2012-09-18T19:44:49Z</dc:date>
    <item>
      <title>automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236104#M18361</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am trying to write a script that takes a single polygon shapefile ( a facility footprint), a grid of planning units, and a landcover shapefile, and, for each planning unit gridcell, shifts the geographic location of the footprint shapefile, and uses the newly located footprint to erase the underlying landcover. What's the best way to iterate through the cells, and aligns the footprint shapefile with the center of the gridcell? Thanks...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Sep 2012 19:44:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236104#M18361</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2012-09-18T19:44:49Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236105#M18362</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Collect the x and y locations of each polygon vertex, in order, as offsets from the lower left corner of the planning unit cell.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Also collect the lower left corner locations for each cell.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Use an Insert Cursor to draw new polygons, vertex by vertex.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For each polygon, use the lower left corner of each cell as the base point, and add the offsets to that for each vertex.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This will give a feature class with all the polygons you want: same shape, different location, &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;each located relative to the cell in which it lands.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Then do just one erase on the landcover.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is likely easier than hopping the same polygon around and erasing each time.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Sep 2012 11:30:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236105#M18362</guid>
      <dc:creator>markdenil</dc:creator>
      <dc:date>2012-09-19T11:30:54Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236106#M18363</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thanks, that sounds like it will do the trick, much obliged!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Sep 2012 13:39:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236106#M18363</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2012-09-19T13:39:02Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236107#M18364</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;So, i feel like i'm almost there, but im getting this error &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Traceback (most recent call last):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;** IDLE Internal Exception: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; File "C:\Python27\ArcGISx6410.1\lib\idlelib\run.py", line 298, in runcode&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; exec code in self.locals&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;File "N:\Projects\120802 CEMA Landscape Simulation Modelling for RMWB\07- Working Products and Drafts\code\trial_run.py", line 51, in &amp;lt;module&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; pntObj.X = pnt.X + xoffset&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;AttributeError: 'NoneType' object has no attribute 'X'&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;using the following script...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;can anyone offer any insight? Thanks!&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
import arcpy, os

dist = r"N:\Projects\120802 CEMA Landscape Simulation Modelling for RMWB\05- Data\glink_seismic_Buffer_ClipExample.shp"
origin = r"N:\Projects\120802 CEMA Landscape Simulation Modelling for RMWB\05- Data\section_for_clipping_disturbance_features.shp"
sqrs = r"N:\Projects\120802 CEMA Landscape Simulation Modelling for RMWB\05- Data\sections_analysis.shp"
outfolder = r"N:\Projects\120802 CEMA Landscape Simulation Modelling for RMWB\05- Data"
outpoly = r"seismic_tile_example.shp"

try:
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Delete_management(outfolder + "/" + outpoly)
except:
&amp;nbsp;&amp;nbsp;&amp;nbsp; pass

arcpy.CreateFeatureclass_management(outfolder, outpoly, "POLYGON", "", "", "", dist)
distdesc = arcpy.Describe(dist)
distshapefieldname = distdesc.ShapeFieldName
squaredesc = arcpy.Describe(sqrs)
squareshapefieldname = squaredesc.ShapeFieldName

originpoly = arcpy.SearchCursor(origin)
squares = arcpy.SearchCursor(sqrs)
inRows = arcpy.SearchCursor(dist)
outRows = arcpy.InsertCursor(outfolder + "/" + outpoly)

polyarray = arcpy.Array()


origindesc = arcpy.Describe(origin)
originshapefieldname = origindesc.ShapeFieldName
orig = originpoly.next()
originvalue = orig.getValue(originshapefieldname)
origincentroid = originvalue.centroid


for square in squares:

&amp;nbsp;&amp;nbsp;&amp;nbsp; squarevalue = square.getValue(squareshapefieldname)
&amp;nbsp;&amp;nbsp;&amp;nbsp; squarecentroid = squarevalue.centroid
&amp;nbsp;&amp;nbsp;&amp;nbsp; xoffset = squarecentroid.X - origincentroid.X
&amp;nbsp;&amp;nbsp;&amp;nbsp; yoffset = squarecentroid.Y - origincentroid.Y

&amp;nbsp;&amp;nbsp;&amp;nbsp; polyIndex = 0
&amp;nbsp;&amp;nbsp;&amp;nbsp; for inRow in inRows:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inShape = inRow.shape
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pntObj = arcpy.Point()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arrayObj = arcpy.Array()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for pnt in inShape.getPart(polyIndex):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pntObj.ID = polyIndex
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pntObj.X = pnt.X + xoffset
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pntObj.Y = pnt.Y + yoffset
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arrayObj.add(pntObj)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outShape = outRows.newRow()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outShape.shape = arrayObj
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; outRows.insertRow(outShape)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; polyIndex += 1



&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 11:54:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236107#M18364</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2021-12-11T11:54:22Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236108#M18365</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I don't see where 'pnt' is defined, so it can't have an attribute 'X'.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 19:28:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236108#M18365</guid>
      <dc:creator>ClayPerry</dc:creator>
      <dc:date>2012-10-03T19:28:27Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236109#M18366</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I don't see where 'pnt' is defined, so it can't have an attribute 'X'.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;its defined in the for loop&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;for pnt in inShape.getPart(polyIndex):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;and i should note that if i add a try: except: routine, some polygons will be written, but not all.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 19:30:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236109#M18366</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2012-10-03T19:30:12Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236110#M18367</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ha, now I see it.&amp;nbsp; It's hard to read unformatted.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So, it looks like you initially get an array of x,y values for the first part of the polygon with this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;for pnt in inShape.getPart(polyIndex):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Now you need to pull the the individual points from the array that is the first part of the first polygon record in your feature class.&amp;nbsp; Think of multipart features.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 19:49:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236110#M18367</guid>
      <dc:creator>ClayPerry</dc:creator>
      <dc:date>2012-10-03T19:49:01Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236111#M18368</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Ha, now I see it.&amp;nbsp; It's hard to read unformatted.&lt;BR /&gt;&lt;BR /&gt;So, it looks like you initially get an array of x,y values for the first part of the polygon with this:&lt;BR /&gt;&lt;BR /&gt;for pnt in inShape.getPart(polyIndex):&lt;BR /&gt;&lt;BR /&gt;Now you need to pull the the individual points from the array that is the first part of the first polygon record in your feature class.&amp;nbsp; Think of multipart features.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;yeah, the posting software seems to be dropping the tabs from the code, my apologies.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But the feature im copying is not multipart...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 19:53:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236111#M18368</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2012-10-03T19:53:15Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236112#M18369</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;First off: use the '#' button in the Forum reply formatting bar to wrap your code in code tags&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;you want:
&amp;nbsp;&amp;nbsp;&amp;nbsp; this&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;instead of:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; this&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would take the original polygon point array and build a nested list of the x,y pairs from it. (featureList)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Then I would make another nested list of the individual squares' origin points.&amp;nbsp; (originList)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;One advantage is that it is easy to inspect these lists if things are not coming out right.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Then the insert cursor just gets created once, and you loop through originList.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;for each origin in originList, you draw a feature &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(one loop through featureList adding the origin x or y to each coordinate)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Your script seems to have nested or overlapping cursors, and you get each origin &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(and each feature point? ...reading unformtted code is confusing at the best of times)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;directly from the reference fc. That just seems overly complex.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Eschew Complexity.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 11:54:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236112#M18369</guid>
      <dc:creator>markdenil</dc:creator>
      <dc:date>2021-12-11T11:54:25Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236113#M18370</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ahh, thanks, hadn't known what the # button did. I've corrected my post above.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;What do you mean by a 'nested list'?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Oct 2012 14:24:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236113#M18370</guid>
      <dc:creator>leifolson</dc:creator>
      <dc:date>2012-10-04T14:24:16Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236114#M18371</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I can see that you are appropriately getting the 1st (and only) part, which is an array (or list?) of point objects....makes sense for single-part features I think.&amp;nbsp; You've set a variable before the loop begins for the 1st part (index 0).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So far so good, you feed adjusted point values based on this into another point array to feed into a new polygon geometry.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Great, but what is the purpose of incrementing your index variable?&amp;nbsp; What other geometry could you be referencing?&amp;nbsp; I think this is at least partly where your mistake is.......every time you fetch a new poly geom with the search, you should only have 1 part, correct?&amp;nbsp; (not considering 'holes' - regardless, the 'single part' should come 1st, if I'm not mistaken)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I agree with the others, better structuring and error trapping would be very useful.&amp;nbsp; Hope this helps.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Oct 2012 23:55:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236114#M18371</guid>
      <dc:creator>T__WayneWhitley</dc:creator>
      <dc:date>2012-10-04T23:55:41Z</dc:date>
    </item>
    <item>
      <title>Re: automated polygon movement?</title>
      <link>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236115#M18372</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;a nested list is a list nested within another list &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(you can nest dictionarys too, and lists within dictionaries and vice versa..)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In this case, you want a list of verticies for the polygon&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;and each vertex entry is a list of the x and y coordinates.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;line this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;theFeatureList = [
&amp;nbsp;&amp;nbsp;&amp;nbsp; [59.9359664290001, 58.2873293230001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [59.9354474180001, 58.292897049],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [59.9359664290001, 58.2873293230001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [15.7361337040001, 69.5741156380001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [5.46961326000007, 74.605524862],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [21.6743239320001, 90.0000000000001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [61.6145099540001, 90.0000000000001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [74.588779291, 78.7328713650001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [74.9956238680001, 62.052243682],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [59.9359664290001, 58.2873293230001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [29.5877337620001, 75.2087581980001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [29.5902670670001, 75.2091884760001],
&amp;nbsp;&amp;nbsp;&amp;nbsp; [29.5877337620001, 75.2087581980001]
&amp;nbsp;&amp;nbsp;&amp;nbsp; ]&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Then, as you loop through the outer list, it returns a llist of xy pairs you can access by index (0 and 1).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Furthermore, if your grid is regular, you needn't make a list of each new anchor point;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;you can just increment the offsets.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;offsetX = 0, offsetY = 0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;draw the first polygon&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;offsetX += cellSizeX&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;draw the second&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;when you finish that row (by counting the steps)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;reset offsetX to 0 and increment offsetY += cellSizeY&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 11:54:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/automated-polygon-movement/m-p/236115#M18372</guid>
      <dc:creator>markdenil</dc:creator>
      <dc:date>2021-12-11T11:54:28Z</dc:date>
    </item>
  </channel>
</rss>

