Sunday, June 20, 2021

 GIS Programming Module 5

This week we have been working on Module 5. In Module 5 we learned to work with various scripts to help interpret geometries. In the exercises for this week we practiced identifying certain portions of geometries and working with text files to write geometries. 

For this module's assignment we had to write a script that will create an empty text file and then we had to write a series of for loops to iterate through a given shapefile and identify the XY coordinates of multipart shapes. Once the loop went through and identified the X,Y coordinates the script had to then write the data to the text file in a clean and coordinated fashion. Below is a flowchart I put together to go over the steps of my script. 


Below is a screenshot of the resulting text file. 





The resulting text file was populated with the feature ID, Vertex ID, X, Y coordinates and the name of the feature. In this case the features are rivers on the island of Maui Hawaii. 

This assignment took some effort as there was lots of looping involved to get the final results. Some trial and error led me to understand how critical indentions are to make sure what needs to be in a loop stays in a loop. 






No comments:

Post a Comment

GIS 6005 Communicating GIS Final I have reached the final assignment of this course. This week we had to put all the skills that we learned ...