Friday, December 13, 2013

Post 6: Python

Background
Python is an open source programming language used to write scripts for ArcGIS.  With the current shift in focus towards interoperability, Python usage is becoming increasingly common as it can be used and distributed by third parties.  Because Python works as both a scripting and programming language, it is capable of running everything from simple scripts to complex, advanced programming tasks.  Additionally, Python scripts are run from the source, directly from the script, which makes them more portable and easier to use than other programming languages (Zandbergen, 19).  The versatility and open accessibility of Python ensure it has a bright future and make it a valuable tool for all GIS users to have.  Thus, our class spent some time working with writing Python script.

Goal
The goal of these exercises was to become familiar with the uses of Python and develop a basic level of proficiency with writing script.

Scripts
In addition to completing several tutorials, we wrote multiple standalone scripts to demonstrate our understanding of Python.
Exercise 1. This script converts coordinates for points from a geographic coordinate system to UTM.
Exercise 5/Python Exercise 6. This script prints the name and geometry of all feature classes in a workspace, such as "road is a line."
Exercise 5/Python Exercise 7. First, this script selects all points designated as airports and creates a 15,000 meter buffer around them. Then, the script selects all points designated as seaplane bases and creates a 7,500 meter buffer around them.  Thus, two new feature classes are created.
Source
Zandbergen, Paul. Python Scripting for ArcGIS. 1st. Redlands: Esri Press, 2013. 19. Print.

No comments:

Post a Comment