Friday, July 25, 2014

GIS Programming Module 9: Debugging

For this week's assignment, we were given three scripts and had to debug and handle the errors in each of them. For the first two, we just had to locate the errors and modify the script so it ran correctly. This was a bit tedious, working through each line, but wasn't too horrible. 

For the third script, we just had to make it run by adding try-except statements to it. After a little trial and error, I managed to get it to work without too much stress. 

This was a surprisingly fun exercise. After getting my undergrad in journalism, I really enjoy reading/editing things. While this is a bit different, it was the same principle so I made the best of it. 

Here's the results from each script:




Friday, July 18, 2014

Module 8: Working with Rasters

For this week's assignment, we were to create a new raster from the data provided. This new raster was to highlight the areas that had forest landcover at 41, 42, and 42, slope between 5 and 20 degrees, and aspect between 150 and 270 degrees.

After working through the exercise, this assignment was pretty painless and stress-free. This is an image of my final product:


Friday, July 11, 2014

Module 7 GIS Programming

For this week's assignment, we were to write a script that created a text file and write it to the coordinates and OIDs for all of the features within the rivers shapefile that was provided.
Other than the usual setbacks, minor syntax errors and so on, this assignment went well up until the end. When I opened the new .txt file, all of the information was there, however, there weren't new lines for each feature. I messed around with PythonWin trying to figure it out until I ran out of time. Perhaps I kept overlooking something? This was my result in the text file: