Lab exercise 10
GEO6513: Advanced GIS, UTSA
Student name: ______
Batch Processing of NEXRAD DSP Data and Analysis
Purpose:
This lab is to design to help you to continue understabding the Python scripting and programming to process massive datasets. Based on the results, you may analyze the results. You are encouraged to add any analytical methods you think are appropriate and useful for the data analysis.
One radar data sets of KEWX at New Braunfels Texas are given, for the Digital Storm Precipitation product (DSP); this is a 4-7 minutes storm accumulation products, from the month of March 2007.
1. Preparation:
Download data and scripts from lab 10 at \\129.115.25.240\XIE_misc\EES6513\ . Open the “kewxMarch07Shapefiles” radar data folder, and check the files formats and names. Create three folders under Lab10 (such as “test1”, “test2”,to ”test3”).
To run the codes you can directly use IDLE (Pyhton GUI), or use ArcGIS; in this lab, we use ArcGIS. Open ArcMap and load all shapefiles under the gisdata folder. Add any one of radar rainfall (DSP) files from “kewxMarch07Shapefiles” folder. Check the data and understand all of them.
Open ArcToobox in ArcMap, add a new Toolbox and name it DSPtool. Right click the DSPtool -> Add-> Script, to add your three scripts into the DSPtool on by one: defineprojection, intersect, and exportAll.
To test the scripts, I suggest you always to start with 2 or 3 files; if success, let it work on all files. To do the test, just copy three shapefiles from “kewxMarch07Shapefiles” into “test1”
Right click defineprojection -> edit, change the inputWS and GP.workspace to your data location: “…\\test1”, run the module. If works, you can do the second step, otherwise, fix the problems.
Right click the intersect -> edit, change all necessary directories to your assigned directories. run the module. If works, you can do the third step, otherwise, fix the problems.
Right click the exportAll -> edit, change all necessary directories to your assigned directories. run the module. Fix any problems, if there is any.
2. run the code
Now you have two ways to continue the lab.
(1). You use the three scripts one by one for all the files. Before you do that, in the “defineprojection” script, you need to change the input data from “test1” to from “kewxMarch07Shapefiles”. In the “intersect” script, you need to change “test1” to “kewxMarch07Shapefiles” as well. In the test2 and test3 directories, you need to delete all the existing files you did during the testing phase, otherwise, it will give an error message.
(2). You first combine three scripts into one script and run it in once. You can use the same data in “test1” to test your script. Once it works, you can apply it to all of your data. By doing this way, you will get extra 20 points. (please attach your final code to your report)
3. Analyze data
Once you finish, copy the resulting data to an excel sheet, use excel to clean up your data and edit it into a format similar as below and calculate the Conditional mean (CM), Standard deviation (SD), Variance, Correlation of Variation (CV). Please refer the reading paper for definitions.
2154 / 2158 / 2202 / 2206 / 2211 / 2215 / 2219 / 2223 / ……. / CM / SD / Va / CVkr20
kr19
kr18
….
….
….
CM
Standard deviation
variance
CV
Use plots to show your results, analyze the spatial and temporal variations of rainfall in the region based on the 50 gauge locations, and report your conclusions.