Creating a shovel test grid for Cultural Resource Management

4020
26
08-05-2017 09:39 AM
EricMai
New Contributor II

I can't find a good amount of information on creating a grid within a set boundary and using the intersection points as points for data.  I work in the archaeology field and we dig shovel tests on a 50 foot grid.  I am trying to figure out a way of creating a grid before entering the field, where each intersection point already has a distinct GPS point, and data can be entered via a database app in reference to each one of these points.  Can anyone help me through this process?

I understand the fishnet tool, but not sure how to use the intersections and create points for each, and additional attributes to be filled in later.  And how could I label each point based off of that grid system of x, y?  For example, transect 1, shovel test 1.  

0 Kudos
26 Replies
EricMai
New Contributor II

Brian, this is exactly what I am looking for!  I would love to see the code you used.  Did you create a workflow model for the tool?  Thank you thank you for this.  

0 Kudos
DanPatterson_Retired
MVP Emeritus

There are code samples here

https://community.esri.com/blogs/dan_patterson/2016/09/09/numpy-snippets-3-phishnyet-creating-sampli...

here

https://community.esri.com/blogs/dan_patterson/2016/09/09/n-gons-regular-polygonal-shape-generation

and xander_bakker‌ posted some as well which also does the labelling, but I can't put my hands on it.

The first link enables, rectangles or hexagon sampling frameworks with or without rotation.

0 Kudos
BrianWilson
Occasional Contributor II

Numpy is elegant, I suppose I will have to start over now. 🙂 Thanks for the link.

0 Kudos
XanderBakker
Esri Esteemed Contributor
0 Kudos
BrianWilson
Occasional Contributor II

I set up a repository on github. I built a python toolbox too and I ran it successfully in ArcGIS Desktop 10.5.1

GitHub - Geo-CEG/shoveltest: Create grids to facilitate shovel tests for archaeology site work. 

If you don't know how to use Github, please ask, I have been thinking of writing a blog post on it.

Please try this tool, I want it to work for you. I am sure there is plenty of tuning I could do on it but I'd like to hear if it is useful first. Next step in the workflow would be to convert the point grid into a GPX file; we should be able to do that in a model though.

In this screenshot I was able to edit the baseline then run the tool right in ArcMap to generate a new grid. Note there are a couple wandering isolated points in this picture -- if a complete square does not fit it will get dropped but the points that still fit inside the polygon were not dropped.

DanPatterson_Retired
MVP Emeritus

Nice Brian!

GitHub's documentation is fairly good.  But Dr. Google  'setting up a package' and other terms as well.

Also, you can link to ArcGIS Code Sharing (bottom left) and share your code from both, and maintain within GitHub

BrianWilson
Occasional Contributor II

I used the "UPLOAD SCRIPTS" at the top of ArcGIS Code Sharing and it set up this in my ArcGIS.com account: Create Shovel Test Grid. However, nothing shows up anywhere that I can see at codesharing. Filtering on Github (by clicking "Github repository" under Result Type) gives Sorry. No results found.

0 Kudos
BrianWilson
Occasional Contributor II

I created a separate question (Code Sharing + Github does not work) since it's a bit off topic here.

0 Kudos
EricMai
New Contributor II

Hi Brian, I've encountered an issue using the tool.  My baseline starts at the upper corner of the red polygon and goes down and to left.  When I run the tool, it only creates a single line of grid points along that edge within the polygon.  Does the tool only draw in one direction from the baseline??

0 Kudos
BrianWilson
Occasional Contributor II

AH, it's rotated 180 degrees -- that is, it builds to the "right" of the line but that's with respect to the baseline so when the line goes north to south

you want to move it over to the other side. Maybe it should build squares on both sides of the baseline to make this easier? Then you could put it anywhere.

0 Kudos