Friday, March 10, 2017

Python Scripts

BACKGROUND

Python is an Integrated Development Environment, or IDE, that allows users to write code, debug, and run it. Scripting is useful when doing repetitive work. Writing a script instead of doing repetitive scripts multiple times can minimize the amount of time it takes to carry out tasks and can minimize room for error.


GOAL

The goal is to learn basic Python scripting and be able to implement it in future work. These scripts should obviously be functional, but also important is that they are well commented so other users can easily understand them.


SCRIPTS

Script 1:


This script projects and clips all rasters within the workspace geodatabase.



Script 2:
This script runs several SQL queries on a vector and saves the results.



Script 3:



This script assigned rasters to variables, weights a variable, and adds them. The result is then saved.


No comments:

Post a Comment