Вы находитесь на странице: 1из 66

CENTRE OF GEOGRAPHIC SCIENCES

CENTRE OF GEOGRAPHIC SCIENCES Practicum Project Practicum GIS GISD 3000 Bronwyn Fleet-Pardy 12/13/2013

Practicum Project

Practicum GIS GISD 3000

Bronwyn Fleet-Pardy

12/13/2013

Practicum Project

Table of Contents

December 13, 2013

Table of Figures

 

iii

Project Overview

1

Study Area/Attaining Data

2

Set-up and Research

3

Project Management

 

3

Creating the File GDB

4

Data Preparation

4

Summary Tables

5

 

6

6

9

Python Scripting

 

10

Creating

12

Creating

12

Importing Feature Classes

 

13

While Loops

14

Importing Description Tables

15

Creating Summary Tables

16

Adding a New Field to Feature Classes

16

Calculating Fields based on Subtype

 

17

Subtype

Management

tools

18

Domain

Management

tools

19

Error Handling

21

Creating the Map

22

 

22

22

23

Study Area

24

Annotation ....................................................................................................................................................................

24

Surround Layout

25

26

Page i

Practicum Project

December 13, 2013

Converting the Geodatabase to an XML document

26

Final Report and Submission

27

Final Map

27

DVD

28

Project Management

28

Time Estimation

28

Data

28

Software

28

29

29

Appendixes

30

DVD Structure

30

Python Script ................................................................................................................................................................

30

Works Cited

a

Page ii

Practicum Project

Table of Figures

December 13, 2013

Figure 1 – The study area of Nova Scotia

2

Figure 2 – Types of GDBs

 

3

 

4

4

5

5

Figure 7 – File GDB with all Feature Datasets and Feature Classes

6

Figure 8 – Feature Class Properties

 

7

 

8

8

Figure 11 – Example of a Model with the Clip tool

9

Figure 12 – Setting the Spatial Reference

11

Figure 13 – Python Script Set

 

11

Figure 14 – File GDB variable

12

Figure 15 – File GDB process

12

 

12

Figure 17 – Feature Dataset process

 

13

 

13

Figure 19 – Importing Feature Class process

14

14

Figure 21 – Description Table variable as a

15

Figure 22 – Importing Description Tables process

15

Figure

23

Summary Statistics tool process

16

Figure 24 – Feature Class List

 

16

Figure 25 – The Add Field process within a While Loop

17

Figure 26 – Calculate Field variables using lists

17

Figure 27 – Calculate Field process

18

19

Figure 29 – Set Default Subtype process

19

Figure 30 – The Create Domain process

19

Figure 31 – Table to Domain process

20

20

Figure 33 – Creating the Style File through the Export Map Styles tool

22

Figure

34

Creating

Layer Files

23

Figure 35 – The building points representation in the Feature Class Properties dialog

23

Figure 36 – The study area as shown in Google Maps

24

Figure 37 – An example of some of the annotation in the chosen study area

25

Figure 38 – An example of the map layout and surround

26

Figure 39 – Exporting the GDB to an XML document

26

Figure 40 – The Final Map product

 

27

Figure 41 – An example of the Project Management Gantt Chart

28

Figure 42 – The structure of the DVD

30

Page iii

Practicum Project

Project Overview

December 13, 2013

This report covers four sections of the project. The segments are outlined below with all processes and tasks documented. A Gantt chart(s) was created and maintained for the client project and is submitted along with this report and the other final products as listed below (Section: Final Report and Submission).

For the first part and second parts of the project, the client gave the task of creating and managing File Geodatabase (GDB) (within ESRI’s ArcGIS 10.1 software suite) for Nova Scotia. It had to include Feature Datasets that incorporated all the Feature Classes for the province. The data decided upon was the Nova Scotia Topographic Database (NSTDB); all layers were to be integrated. Once the data was obtained for the clients use, it was brought into the GDB and the Feature Classes had Subtypes and Domains subsequently generated (Section: Part One: Creating the File GDB).

The difference between the first and second part was that the second File GDB and all subsequent features were created in a Python script. Python is an open source programming language that is object based. It was incorporated into the ESRI software package starting at version 10. The main benefit of using a script is that it can be executed time and time again, as long as the data, syntax and parameters remain unchanged. The client requested that Python be used since it incorporates all the ArcGIS functionalities (Section: Python Scripting).

The third portion of the client project was to create a topographic map for a chosen study area. The map symbology had to replicate the National Topographic Series (NTS) as much as possible. Various forms of styling techniques had to be used to create Style Files, Layer Files and Representation Files. This was performed for every feature contained in the NSTDB GDB (Section: Creating the Map).

To complete the project, the analyst completed data management for all files related to and used within the project. A final submission was compiled with a hard and soft copy of the final draft of the map and the final report documenting all the processes and tasks. A digital submission of all intermediate files was also given to the client (Section: Final Report and Submission).

Page 1

Practicum Project

December 13, 2013

Study Area/Attaining Data

The analysts that were working together decided that the study area would be Nova Scotia and since the company (the Centre of Geographic Sciences – COGS) has an agreement with the Nova Scotia Geomatics Centre (NSGC) to supply COGS with an updated copy of the seamless NSTDB every year. The NSTDB was decided upon since it included all the major features of Nova Scotia (subsequently they were assimilated in the GDB in the major Feature Datasets, Feature Classes, etc.). The 2013 version of the data had just been supplied to COGS, the analysts involved in the project choose to use the 2013 version since they all had previous experience with the 2012 version and wanted to see what modifications had been completed on the updated dataset. The data was readily available on the COGS Mapping Server to be copied onto the analysts’ processors.

Practicum Project December 13, 2013 Study Area/Attaining Data The analysts that were working together decided that

Figure 1 – The study area of Nova Scotia

Note: The organization ended up having to use several sections of the 2012 NSTDB data layers because the 2013 version was missing certain parts that were essential to the project. Emails have been sent to the NSGC concerning the matters and the analysts are waiting for a reply as of this date.

Page 2

Practicum Project

Set-up and Research

December 13, 2013

The analysts were required to do research on what kind of a GDB to use since the dataset was quite large (approximately 4.80 gigabytes – GB –). ESRI Personal GDBs only store up to 2 GB thus that GDB type was impractical for storing the dataset. The largest version of a GDB available would be an ArcSDE GDB; however, none of the analysts had previous experience with that GDB type. A File GDB was decided upon since it is the most versatile within the GIS industry, its capacity is 500 GB; it is editable by more than one person, can be shared with others and has a clean organized interface.

Practicum Project Set-up and Research December 13, 2013 The analysts were required to do research on

Figure 2 – Types of GDBs

Project Management

Project management techniques are useful and needed for many reasons: A detailed description of every task, action, development and required time was documented and several portions were utilized for this report. Creating a file to document the steps taken to generate the project along with the time required can justify why certain tasks took a specific amount of times if the procedures came under skepticism.

Thus a Project Management Spreadsheet was developed to include all the above details along with estimated times for everything. A chart was created in Microsoft Excel 2010 to document every feasible aspect of the project. Each process had an estimated hour(s) and actual hour(s) column, and a start and finish date column.

Page 3

Practicum Project

December 13, 2013

Part One : Creating the File GDB

Creating the File GDB

Data Preparation

To prepare the NSTDB dataset for the File GDB it had to be reviewed and the attributes were assessed for quality control. The data was brought into both ArcCatalog and ArcMap (version 10.1) to evaluate graphic product and examine the attributes as mentioned above.

As noted above in the Study Area / Attaining Data section, several processes had to be conducted to see if 2013 would be valuable for the project. An example of that would have been when the analysts were assessing the 2013 Hydrographic Network (NSHN) data: It was noted that numerous water features appeared to be duplicated, in the attributes of the features that had varying numbers and that various records did not match were records were supposed to (Copy files for the point, line and polygon water features existed with differing issues within each of the attribute tables).

The analysts believed that joining the copy files could be the solution; nevertheless numerous techniques were undertaken with nothing prevailing.

Practicum Project December 13, 2013 Part One : Creating the File GDB Creating the File GDB

The Select by Location tool was then used to try to eliminate the copy files

Practicum Project December 13, 2013 Part One : Creating the File GDB Creating the File GDB

Figure 3 – NSTDB Seamless

2013

issue. Once the features were selected, an edit session commenced in ArcMap; however none of the analysts were able to actually combine the copy and non-copy files together and delete the matching records since ArcMap would crash every time the delete button was pressed in the edit session.

The analyst then chose to use the 2012 NSHN feature classes for the Hydrographic content of the project.

Figure 4 – Select By Location tool

Page 4

Practicum Project

Summary Tables

December 13, 2013

Once the functional NSHN was combined with the rest of the NSTDB data, the feature codes of

NSTDB had to be summarized in ArcMap via each attribute table of each file.

By right clicking and selecting Summarize on the FEAT_CODE tab, the summarize table displays and allows the analysts to save the summary table as a dbf table. The dbf table format can be opened in Microsoft Excel (in an xlsx format) where an additional column called DESCRIPTION was added for the feature codes explanation (which was used to create the Subtypes and Domains – see Subtypes and Domains section).

The feature codes descriptions were obtained from the NSGC website, if a feature codes description could not be found, the analyst populated the field with whatever feature codes description that resembled it best.

Practicum Project Summary Tables December 13, 2013 Once the functional NSHN was combined with the rest

Figure 5 – Summarizing

Practicum Project Summary Tables December 13, 2013 Once the functional NSHN was combined with the rest

Figure 6 – The NS Government website

Page 5

Practicum Project

December 13, 2013

Constructing a Geodatabase

A File GDB had to be created in ArcCatalog by right clicking the project folder and selecting New and File Geodatabase. The analysts choose that the major Feature Datasets would be as displayed in the SUBTYPES table (See – Subtypes and Domains). All the feature classes were than distributed into the accurate Feature Datasets that corresponded with the descriptions for the feature codes.

Practicum Project December 13, 2013 Constructing a Geodatabase A File GDB had to be created in

Figure 7 – File GDB with all Feature Datasets and Feature Classes

Subtypes and Domains

A SUBTYPES xlsx file was created to show two fields: Code and Description. The two fields were populated as such; the code field displayed numbers from 1 to 9 that corresponded with descriptions as shown in the table. Once the xlsx file was created ArcCatalog, it was imported using the Table to Table tool, by the analyst, into the NSTDB GDB. For each Feature Class a series of steps had to be performed (in ArcCatalog) for the final Subtype and Domain outcomes, the processes were as follows.

The properties of each specific Feature Class that was being modified were altered to add a field called SUBTYPE that was a long integer data type.

The Calculate Field tool was then used on each Feature Class as the input. The field name specified for all of the added fields was SUBTYPE, the expression used corresponded to the description of the Feature Datasets of the Feature Class that being calculated.

Page 6

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 8 – Feature Class Properties Once the Calculate Field tool

Figure 8 – Feature Class Properties

Once the Calculate Field tool was run on each Feature Class, the analyst added into the Subtypes category in the properties, the codes and descriptions for each Feature Dataset.

The Table to Domain tool was then used on the xlsx sheet that corresponded to each Feature Class as the input. The code field was feature code, the description field was description, the input workspace was the NSTDB GDB, the domain name coordinated with whatever the Feature Class was being modified and the domain description matched the Feature Datasets description. The domain in the properties could then be set for the feature code that matched the Feature Class.

The Subtypes and Domains were generated to make symbolization quicker for all of the features of Nova Scotia in the GDB.

Page 7

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 9 – Calculate Field Tool dialog Figure 10 – Table

Figure 9 – Calculate Field Tool dialog

Practicum Project December 13, 2013 Figure 9 – Calculate Field Tool dialog Figure 10 – Table

Figure 10 – Table to Domain tool dialog

Page 8

Practicum Project

December 13, 2013

How Scripts and Models would benefit in the future:

The Python programming language (which ArcGIS uses as a scripting language for Geoprocessing activities) is an open source software application that is object oriented. Python scripts can automate workflows and ultimately make tedious processes finish more rapidly with equally respectable results. A script can create an achievement of gathering and deploying information in the exact way that the scripter designed for the processes. Scripting for the project will be utilized by the employees for the final outcomes and subsequent project when it is continued.

Models in ArcGIS are excellent visual presentations of tasks as well as being able to automate the processes, especially repetitive actions that can also complete Geoprocessing procedures quickly. ESRI developed the ModelBuilder application that is easy to use and displays all of the Geoprocessing inputs, any other features needed (such as a clip feature) as well as an output feature.

Practicum Project December 13, 2013 How Scripts and Models would benefit in the future: The Python

Figure 11 – Example of a Model with the Clip tool

Page 9

Practicum Project

December 13, 2013

Part Two : Python Scripting

Python Scripting

As mentioned above (Section: Project Overview) a Python script is a great way to automate the creation of the File GDB and all the subsequent features. The Python GDB can be repeatedly recreated as desired for the client. The data, variables and parameters could be altered to produce a different GDB with different data for the same or similar results.

In order to start a script, the ArcPy (“arcpy”) module needed to be imported into the workspace for the script to function properly. The ArcPy module carries out all the ArcGIS functionalities and tools, such as the Clip and Buffer tools. The “sys” and “os” modules were also imported. The “sys” would import all the systems specific parameters and functions. The “os” would import the Operating Systems functionalities; in this case it would be the Windows Operating System. These were all imported to ensure that the processes in the script would serve their purpose and create the appropriate outcomes.

The workspace and environment settings had to be established in order for the script to run. The workspace is where the data was stored and called upon. The outputs of the scripts processes were also stored in that specific location.

Variables had to be created and selected for most of the processes. All of the Feature Datasets and Feature Classes had variables set as well as the File GDB. A variable is a name that can be called to represent a value, even if that value may change. Variables can represent more than one value or object at a time as well. Variables can be concise and simple word structures for less unproblematic scripting. If a simple word is used as a variable that describes a list of features, it is less likely for syntax and parameter issues, such as misspelling a word.

Before the GDB in the script would be generated, the Spatial Reference was set using the “arcpy.SpatialReference” tool. The Spatial Referenced needed to be set to create the Feature Datasets.

Page

10

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 12 – Setting the Spatial Reference To look further at

Figure 12 – Setting the Spatial Reference

To look further at the script please see section: Appendixes, Python Script.

Practicum Project December 13, 2013 Figure 12 – Setting the Spatial Reference To look further at

Figure 13 – Python Script Set Up

Page

11

Practicum Project

December 13, 2013

Creating the Geodatabase

In order to create a File GDB, the “arcpy.CreateFileGDB_management” tool was used. The new GDB was called “fGDB” and given the variable “out_dataset_path”.

Practicum Project December 13, 2013 Creating the Geodatabase In order to create a File GDB, the

Figure 14 – File GDB variable

Practicum Project December 13, 2013 Creating the Geodatabase In order to create a File GDB, the

Figure 15 – File GDB process

Creating Feature Datasets

Once the GDB was created, Feature Datasets needed to be created for the subsequent feature classes. There were two options to generate the Feature Datasets in conjunction with the NSTDB dataset. The setup for the Feature Datasets could either be by Point Line or Polygon features. Or have the Feature Datasets set up based off of the nine different categories of feature classes (i.e. BL, DA, etc.). The later was chosen by the client, as displayed in figure 16.

The first tool used was the “arcpy.CreateFeatureDataset_management”. This was run with variables for each Feature Dataset.

Practicum Project December 13, 2013 Creating the Geodatabase In order to create a File GDB, the

Figure 16 – Feature Dataset variables

Page

12

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 17 – Feature Dataset process Importing Feature Classes The feature

Figure 17 – Feature Dataset process

Importing Feature Classes

The feature classes for all the NSTDB data were than imported into the newly created Feature Datasets. This was performed using the “arcpy.FeatureClassToGeodatabase_conversion” tool.

Practicum Project December 13, 2013 Figure 17 – Feature Dataset process Importing Feature Classes The feature

Figure 18 – Importing Feature Class variables

Page

13

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 19 – Importing Feature Class process While Loops While loops

Figure 19 – Importing Feature Class process

While Loops

While loops were used to iterate through some of processes that had more than one feature being altered. For however many features being processed in the while loop, a total and a counter need to be present. If there were 26 features, the total would be 25 and the counter would start at 0. To complete a while loop and end it (without the loop never finishing), a counter = counter + 1 had to be included. Using a list of features works well for ArcPy tools inside a while loop.

Practicum Project December 13, 2013 Figure 19 – Importing Feature Class process While Loops While loops

Figure 20 – An example of a tool process executed with a While Loop

Page

14

Practicum Project

December 13, 2013

Importing Description Tables

The description tables from the first portion of the project were used again for the script and imported into the GDB. The descriptions tables were used to help create the domains. To import the tables into the script GDB, the analyst used a while loop and the “arcpy.TableToGeodatabase_conversion” tool. There were 26 tables that were imported. They each corresponded to the individual feature classes.

Practicum Project December 13, 2013 Importing Description Tables The description tables from the first portion of

Figure 21 – Description Table variable as a List

Practicum Project December 13, 2013 Importing Description Tables The description tables from the first portion of

Figure 22 – Importing Description Tables process

Page

15

Practicum Project

December 13, 2013

Creating Summary Tables

The summary tables were created to determine if there were “null” features within the various feature classes. This would allow for Subtypes and Domains to be properly set with minimal to no errors or complications. The “arcpy.Statistics_analysis” tool was used with a try and except statement. It was based on the “FEAT_CODE” and “FIRST”. Each feature class was processed individually with the tool.

Practicum Project December 13, 2013 Creating Summary Tables The summary tables were created to determine if

Figure 23 – Summary Statistics tool process

Adding a New Field to Feature Classes

The Add Field tool was processed in a while loop with the list of all 25 feature classes in the GDB. The new field created was called “Subtype” and it was a long integer. The new field will be used to calculate the feature classes corresponding with the appropriate feature category.

Practicum Project December 13, 2013 Creating Summary Tables The summary tables were created to determine if

Figure 24 – Feature Class List

Page

16

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 25 – The Add Field process within a While Loop

Figure 25 – The Add Field process within a While Loop

Calculating Fields based on Subtype

The Calculate field was processed in two ways, depending how many feature classes were in a Feature Dataset(s). Based on the previously decided feature code descriptions, all the feature classes in each Feature Dataset were divided into nine categories. For the Feature Datasets that only had one feature class, the “arcpy.CalculateField_management” tool was executed with a try and except statement. For the Feature Datasets that contained one or more feature classes, the “arcpy.CalculateField_management” was executed within a while loop to iterate the process on all the feature classes.

Practicum Project December 13, 2013 Figure 25 – The Add Field process within a While Loop

Figure 26 – Calculate Field variables using lists

Page

17

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 27 – Calculate Field process Subtype Management tools The subtypes

Figure 27 – Calculate Field process

Subtype Management tools

The subtypes were created in order to apply a default value to the features based on the description tables.

There were three tools to run for creating the subtypes within the script GDB. The first was the “arcpy.SetSubtypeField_management” tool that would set the field being used for the subtype to the newly generated “Subtype” field.

Practicum Project December 13, 2013 Figure 27 – Calculate Field process Subtype Management tools The subtypes

Page

18

Practicum Project

December 13, 2013

Figure 28 – Set Subtype Field and Add Subtype processes

The second tool executed was the “arcpy.AddSubtype_management”, this was performed on each individual feature class but still based on the nine feature categories created to classify them (Section:

Appendixes for full processes and variables).

Practicum Project December 13, 2013 Figure 28 – Set Subtype Field and Add Subtype processes The

Figure 29 – Set Default Subtype process

The third process was to set the default subtype. This was performed using the “arcpy.SetDefaultSubtype_management” tool and was also performed on each individual feature class. The tool would give the feature a default number based on the nine feature categories.

Domain Management tools

The Domains were created to show values in a chosen field. One domain can be used for multiple feature classes as long as they have the same field in the attribute table. For this script, it was the “Subtype” field that was added.

There were three tools to execute for the domains to properly function.

The first step was to create the domain. This was performed by using the “arcpy.CreateDomain_management” tool. Several parameters were needed for the tool to function. The script GDB had to be the input feature, then the individual feature class name, than the description. This was based on the “TEXT” and “CODED” fields and was set as default.

Practicum Project December 13, 2013 Figure 28 – Set Subtype Field and Add Subtype processes The

Figure 30 – The Create Domain process

Page

19

Practicum Project

December 13, 2013

The second stage of creating the domains required the “arcpy.TableToDomain_management” tool. This tool uses the imported description tables and creates a domain from each one. Then by running the “arcpy.AssignDomainToField_management” tool, the domains are applied to the appropriate feature class(es).

Practicum Project December 13, 2013 The second stage of creating the domains required the “arcpy.TableToDomain_management” tool.

Figure 31 – Table to Domain process

Creating the subtypes and domains can be excellent forms for an analyst to perform quality control and reducing the chance of user input inaccuracies. However, for this project subtypes and domains were used to automatically assign basic symbology to the various feature classes.

Practicum Project December 13, 2013 The second stage of creating the domains required the “arcpy.TableToDomain_management” tool.

Figure 32 – Assign Domain to Field process

Creating a Script Tool from the Python script could also be beneficial to the client. If they did proceed that way, there could be user specified inputs such as changing the workspace and data for specific projects the organization may want to generate.

Page

20

Practicum Project

Error Handling

December 13, 2013

Variables can be used an as error handling technique because, as mentioned above, they can reduce the likelihood of syntax and spelling errors created by the user or analyst.

Print statements were used for every process and task undertaken in the script. A print statement allows the analyst to write a short message that would display on the screen as the script runs through that specific portion of the script. Print statements were added before and after each step and tool.

Try and Except statements are used as a way to try the tool and if the tool processes, the script would move onto the next procedure. The except portion of the statement is processed if the script is unable to run the process and it fails. If the tool or step does not run, a print statement will appear on the screen to let the user know.

The only place in the script where the try and except statement was not used (besides the While Loop sections) was with the Table to Domain tool processes for all the feature classes incorporated into the GDB. The analyst was unable to determine why the tool would error out with this functionality but successfully run without it.

The Del ArcPy (“del arcpy”) function was used to eliminate any schema locks in the script or with the other ArcPy functions and tools. This was placed at the end of the script once all the processes were accomplished.

The analyst paid close attention to the syntax and parameters of the script to help enforce and decrease topographic errors.

Please see the Appendixes section for further details.

Page

21

Practicum Project

December 13, 2013

Part Three : Creating the Map

Creating the Map

A hard copy and soft topographic map had to be produced manually through ArcMap and ArcCatalog

10.1.

This was accomplished using the first GDB and subsequent files created at the beginning of the project.

Generating Style File

The style files were the first portion of the symbology files generated for the map. Every features style had to be manually created by the analyst In ArcMap. This was based off of the NTS specifications. After all the individual feature classes had styles created, the Export Map Styles tool in ArcMap was used to export the style files to .style extension. The newly produced style file could then be applied to those feature classes again if and when necessary.

Practicum Project December 13, 2013 Part Three : Creating the Map Creating the Map A hard

Figure 33 – Creating the Style File through the Export Map Styles tool

Creating Layer Files

Layer files were produced as another type of symbology. Modifications by the analyst had been made to some of the symbology and were saved as layer files. This was performed by right clicking on a feature class in ArcMap and choosing Save As Layer File option.

Page

22

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 34 – Creating Layer Files The Representation Files The symbology

Figure 34 – Creating Layer Files

The Representation Files

The symbology had to be converted to Representation Files, as requested by the client. This was performed so that the symbology would be present in the GDB. Representation files can be used for generalizing symbology. The analyst however, did not modify anymore symbology at this point.

Practicum Project December 13, 2013 Figure 34 – Creating Layer Files The Representation Files The symbology

Figure 35 – The building points representation in the Feature Class Properties dialog

Page

23

Practicum Project

Study Area

December 13, 2013

The client was open to determining a study area anywhere in the Nova Scotia, for the topographic map. The analyst presented several locations to client and they mutually decided upon the Kejimkujik Lake area in central Nova Scotia.

Practicum Project Study Area December 13, 2013 The client was open to determining a study area

Figure 36 – The study area as shown in Google Maps

Annotation

Annotation for the map was created with a Visual Basic (VB) script supplied by the client. The annotation was placed on the map in the approximate areas where it would match the features but the analyst had to manually place text pieces for most of the study area. The water features, such as brooks and lakes had to be manipulated to better display each feature accordingly to cartographic standards.

All annotation from the VB script had a halo placed around it for an improved cartographic appearance. The halo masked out features underneath the text that would have overlapped or cluttered up the map.

Additional annotation was added for the contour index features on the map. This was implemented to achieve a better cartographic map and for the user of the map to be able to see the elevation in the study area. All annotation was converted and stored in the GDB.

Page

24

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 37 – An example of some of the annotation in

Figure 37 – An example of some of the annotation in the chosen study area

Surround Layout

All features for the layout were created by the analyst in an ArcMap documents except the loon logo, which was created using Adobe Photoshop CS6.

The maps features and surround layout were based off of the NTS map sheet series. In this case, it was an older map sheet from the 1990s. Only the roads legend was added to the layout since the older NTS map sheets had the rest of the legends on the back of the map.

The creation of the layout was a tedious process but the final results closely resembled the map sheet that the analyst was replicating for the client. A TIFF file (.tif) of the NTS map sheet was used as reference and placed under the features generated by the analyst.

The NTS fonts that were specified did not exist on the analyst’s workstation. Thus the client and the analyst decided to use Tahoma and Ariel for all the features in the surround and on the map.

Page

25

Practicum Project

December 13, 2013

Practicum Project December 13, 2013 Figure 38 – An example of the map layout and surround

Figure 38 – An example of the map layout and surround

First Draft Map Product

The first draft of the map was submitted to the client at one of the weekly meetings. This was done so that the client could see progress as well as to give feedback to the analyst. The client critiqued the rough draft of the map, giving many positive comments for improvements. The analyst complied and immediately made the changes to the map.

Converting the Geodatabase to an XML document

Converting the GDB to an XML document is a short practice but necessary. An XML document is an excellent way to display all files and features in a File GDB without actually looking at the GDB in person. This was given to the client so they could determine if all the required elements were present.

Practicum Project December 13, 2013 Figure 38 – An example of the map layout and surround

Figure 39 – Exporting the GDB to an XML document

Page

26

Practicum Project

December 13, 2013

Part Four : Final Report and Submission

Final Report and Submission

The final pieces for submissions were as follows: A hard copy of the final map, a hard copy of the final written report and a DVD containing the compressed compilation of all files that are related to the client project.

Final Map

The final hard copy map had to be tri-folded, displaying the cover section as the first piece of information that the client would see. It was folded and placed inside the client project binder with the other submission pieces.

Practicum Project December 13, 2013 Part Four : Final Report and Submission Final Report and Submission

Figure 40 – The Final Map product

Page

27

Practicum Project

DVD

December 13, 2013

The DVD contains all files that are in conjunction with the project. This includes: All intermediate data, processes performed, notes, and ArcMap documents (.mxd). Reports, PDFs and TIFFs of draft plots for the map were placed in the Lab3 PDF folder, as well as the final soft copies are placed in the Lab4 PDF folder. The Project Management Gantt charts are in the Project Management folder.

Project Management

Project Management Gantt charts were kept and compiled after every weekly client meeting. The Gantt chart includes the estimated and actual times for each section of the project, the dates, and analyst’s comments. It was also submitted as a hard and soft copy.

Practicum Project DVD December 13, 2013 The DVD contains all files that are in conjunction with

Figure 41 – An example of the Project Management Gantt Chart

Time Estimation

The analyst was able to perform many of the tasks accordingly with the estimated time for each section. However, errors in the data, software glitches and processing tools took longer to run then estimated and was noted in the Gantt chart by the analyst for the client to see.

Data

NSTDB Seamless 2012 and 2013

Software

ESRI’s ArcGIS 10.1 suite

Python 2.7

Page

28

Practicum Project

Adobe Photoshop CS6

Corel PHOTOPAINT X6

Microsoft 2010 suite

Lessons Learned

December 13, 2013

Datasets should be thoroughly examined before deciding that the data will function appropriately. The 2013 NSTDB Seamless data was missing attributes and feature classes. Some of the feature classes had duplicates but looked different when analyzed and had different attributes that did not match.

The analyst learned that not every process will proceed smoothly and that issues will always appear no matter how meticulous they are.

Conclusion:

For the first portion the final outcome for adding the subtypes and domains was to make symbolization quicker for all the features in the GDB. Essentially, when the feature classes are added to an ArcMap document, they should come in symbolized based on the feature code descriptions.

The second portion of the project replicated the first portion but in Python scripting with similar results.

The third portion of the project was to manually recreate an NTS map sheet with accompanying Style Files, Layer Files and Representation Files.

The fourth portion was the final written report, final draft of the map and the DVD compilation.

Page

29

Practicum Project

Appendixes

December 13, 2013

DVD Structure

The Final Reports folder contains all the reports written in for the entire project. Several of them are rough drafts.

The Lab2Python folder contains the Python script, data, created GDB, XLSX files, DBF files and the XML document.

The Lab3 folder contains subfolders for specific sections of the project. There are folders for the images that appear on the map surround, a folder for the study area clip, folders for the ArcMap documents. The PDF folder contains all the plots for the rough draft of the map. The Symbology Files folder contains the Style File and Layer files for the map.

The Lab4 folder contains a folder for the screen shots for the written report. An ArcMap document folder for the final maps MXDs. The PDF folder contains all the final plots.

The MapSheet folder contains the Kejimkujik Lake canmatrix files,

TIFF and PDF of the old NTS map sheet.

Practicum Project Appendixes December 13, 2013 DVD Structure The Final Reports folder contains all the reports

Figure 42 – The structure of the DVD

The NSTDB.gdb is the first created File GDB.

The Project Management folder contains all the Gantt Charts created over the duration of the project.

The Style File folder contains the Style File created in the second part of the project.

The Weekly folders contain any intermediate data or files supplied by the client for the project. The project was 15 weeks long but the analyst did not always receive files every week. Thus the folders present are representative of the weeks the client did give the analyst files.

Python Script

############################################################################ #Practicum GIS - Python Scripting #Lab 2 #Date: Fall 2013 #This script was created by Bronwyn Fleet-Pardy #This script was produced for the Practicum GIS 3000 course #Description: This script uses ESRI's ArcPy Geoprocessing tools to create a File Geodatabase, #Feature Datasets and Feature Classes for all of the Nova Scotia Topographic Database (NSTDB). #Subtypes and Domains were created and assigned. ############################################################################

Page

30

Practicum Project

December 13, 2013

#Imports the ArcPy site package for ArcGIS functionality import arcpy, os, sys

print ("Importing ArcPy and Operating Systems")

#Imports ArcGIS Environments Settings from arcpy import env

print ("Importing Environment Settings")

#Modifies env setting to overwrite existing files arcpy.env.overwriteOutput = True

print ("Overwrite existing files set to True")

#Modifies environments settings to the current workspace env.workspace = "D:/GISD3000_GIS_Practicum/Lab2Python"

print ("Workspace defined")

############################################################################ #Geoprocessing Tools ############################################################################ #Set variables:

print ("Setting variables")

#File Geodatabase out_dataset_path = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb"

#Feature Datasets out_name0 = "BL" out_name1 = "DA" out_name2 = "DL" out_name3 = "LC" out_name4 = "LF" out_name5 = "RR" out_name6 = "ST" out_name7 = "UT" out_name8 = "WA"

#The input features for the Feature to Geodatabase process. inFeatures0 = ["bl_point.shp", "bl_poly.shp"] inFeatures1 = ["da_poly.shp"] inFeatures2 = ["dl_line.shp"] inFeatures3 = ["lc_line.shp", "lc_point.shp", "lc_poly.shp"] inFeatures4 = ["lf_break.shp", "lf_line.shp", "lf_spot.shp"] inFeatures5 = ["rr_line.shp", "rr_point.shp", "rr_poly.shp", "nsrn_distrib.shp"] inFeatures6 = ["st_line.shp", "st_point.shp", "st_poly.shp"] inFeatures7 = ["ut_line.shp", "ut_point.shp", "ut_poly.shp"] inFeatures8 = ["nshn_lake_poly.shp", "nshn_wa_cent.shp", "nshn_wa_line.shp", "nshn_wa_point.shp", "nshn_wa_poly.shp"]

#The location for the output from importing the Feature Classes to the Geodatabase. outLocation0 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL"

Page

31

Practicum Project

December 13, 2013

outLocation1 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DA" outLocation2 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DL" outLocation3 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC" outLocation4 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF" outLocation5 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR" outLocation6 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST" outLocation7 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT" outLocation8 = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA"

#List of all feature classes tables. tableList = [

"D:/GISD3000_GIS_Practicum/Lab2Python/bl_point.xlsx/bl_point$",

"bl_poly.xlsx\\bl_poly$", "da_poly.xlsx\\da_poly$", "dl_line.xlsx\\dl_line$", "lc_line.xlsx\\lc_line$", "lc_point.xlsx\\lc_point$", "lc_poly.xlsx\\lc_poly$", "lf_break.xlsx\\lf_break$", "lf_line.xlsx\\lf_line$", "lf_spot.xlsx\\lf_spot$", "nshn_lake_poly.xlsx\\nshn_lake_poly$", "nshn_wa_cent.xlsx\\nshn_wa_cent$", "nshn_wa_line.xlsx\\nshn_wa_line$", "nshn_wa_point.xlsx\\nshn_wa_point$", "nshn_wa_poly.xlsx\\nshn_wa_poly$", "nsrn_distrib.xlsx\\nsrn_distrib$", "rr_line.xlsx\\rr_line$", "rr_point.xlsx\\rr_point$", "rr_poly.xlsx\\rr_poly$", "st_line.xlsx\\st_line$", "st_point.xlsx\\st_point$", "st_poly.xlsx\\st_poly$", "ut_line.xlsx\\ut_line$", "ut_point.xlsx\\ut_point$", "ut_poly.xlsx\\ut_poly$",

"Subtype.xlsx\\Sheet1$"]

#Feature Class List. The new field Subtype will be added to them. fcList = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DA/da_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DL/dl_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_break_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_spot_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_lake_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_cent_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/nsrn_distrib_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_poly_shp"]

#The variables for the Calculate Field put into Lists. listBL = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_point_shp",

Page

32

Practicum Project

December 13, 2013

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_poly_shp"]

listDA = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DA/da_poly_shp" listDL = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DL/dl_line_shp" listLC = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_poly_shp"]

listLF = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_break_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_spot_shp"]

listRR = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/nsrn_distrib_shp"]

listST = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_poly_shp"]

listUT = ["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_poly_shp"]

listWA =

["D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_lake_poly_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_cent_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_line_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_point_shp",

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_poly_shp"]

#Hard coded variables for Adding the Subtype to each feature class. bl_point = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_point_shp" bl_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/BL/bl_poly_shp" da_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DA/da_poly_shp" dl_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/DL/dl_line_shp" lc_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_line_shp" lc_point = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_point_shp" lc_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LC/lc_poly_shp" lf_break = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_break_shp" lf_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_line_shp" lf_spot = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/LF/lf_spot_shp" nshn_lake_poly =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_lake_poly_shp"

nshn_wa_cent =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_cent_shp"

nshn_wa_line =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_line_shp"

nshn_wa_point =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_point_shp"

nshn_wa_poly =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/WA/nshn_wa_poly_shp"

rr_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_line_shp" rr_point = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_point_shp" rr_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/rr_poly_shp" nsrn_distrib =

"D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/RR/nsrn_distrib_shp"

st_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_line_shp" st_point = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_point_shp" st_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/ST/st_poly_shp" ut_line = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_line_shp"

Page

33

Practicum Project

December 13, 2013

ut_point = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_point_shp" ut_poly = "D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gdb/UT/ut_poly_shp" print ("Variables defined")

#This script was created by Bronwyn Fleet-Pardy

#Creating a spatial reference object try:

print ("Setting Spatial Reference")

sr = arcpy.SpatialReference("D:/GISD3000_GIS_Practicum/Lab2Python/NAD 1983 CSRS UTM Zone 20N.prj")

print ("Spatial Reference defined") except:

print ("Spatial Reference definitation failed, try again")

#Create File Geodatabase try:

print ("Creating file Geodatabase")

arcpy.CreateFileGDB_management("D:/GISD3000_GIS_Practicum/Lab2Python/",

"fGDB.gdb")

print ("File Geodatabase generated") except:

print ("File Geodatabase creatation failed, try again")

#Create Feature Datasets try:

print ("Creating Feature Datasets")

arcpy.CreateFeatureDataset_management(out_dataset_path, out_name0, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name1, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name2, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name3, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name4, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name5, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name6, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name7, sr) arcpy.CreateFeatureDataset_management(out_dataset_path, out_name8, sr)

print ("Feature Datasets created") except:

print ("Feature Datasets generation failed, try again")

#This script was created by Bronwyn Fleet-Pardy

#Execute Feature Class to Geodatabase try:

print ("Feature Class to Geodatabase excuting")

arcpy.FeatureClassToGeodatabase_conversion(inFeatures0, outLocation0) arcpy.FeatureClassToGeodatabase_conversion(inFeatures1, outLocation1) arcpy.FeatureClassToGeodatabase_conversion(inFeatures2, outLocation2)

Page

34

Practicum Project

December 13, 2013

arcpy.FeatureClassToGeodatabase_conversion(inFeatures3, outLocation3) arcpy.FeatureClassToGeodatabase_conversion(inFeatures4, outLocation4) arcpy.FeatureClassToGeodatabase_conversion(inFeatures5, outLocation5) arcpy.FeatureClassToGeodatabase_conversion(inFeatures6, outLocation6) arcpy.FeatureClassToGeodatabase_conversion(inFeatures7, outLocation7) arcpy.FeatureClassToGeodatabase_conversion(inFeatures8, outLocation8)

print ("Feature Class to Geodatabase process succeeded") except:

print ("Feature Class to Geodatabase process failed, try again")

#Process Import Description Tables print ("Executing Import Description Tables") total = 25 counter = 0 while counter <= total:

arcpy.TableToGeodatabase_conversion(tableList [counter], out_dataset_path) counter = counter + 1 print ("Description tables executed")

#This script is created by Bronwyn Fleet-Pardy

#Add Fields print ("Adding Fields to individual Feature Classes") total = 24 counter = 0 while counter <= total:

arcpy.AddField_management(fcList[counter], "Subtype", "LONG") counter = counter + 1 print ("Add Fields have been added to each Feature Class")

#Execute Summary Statistics - BL Point print ("Creating Summary Table for BL Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/BL/bl_point_shp", "bl_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for BL Point Created") except:

print ("BL Point Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - BL Poly print ("Creating Summary Table for BL Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/BL/bl_poly_shp", "bl_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for BL Poly Created") except:

print ("BL Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - DA Poly print ("Creating Summary Table for DA Poly") try:

Page

35

Practicum Project

December 13, 2013

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/DA/da_poly_shp", "da_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for DA Poly Created") except:

print ("DA Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - DL Line print ("Creating Summary Table for DL Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/DL/dl_line_shp", "dl_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for DL Line Created") except:

print ("DL Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - LC Line print ("Creating Summary Table for LC Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LC/lc_line_shp", "lc_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LC Line Created") except:

print ("LC Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - LC Point print ("Creating Summary Table for LC Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LC/lc_point_shp", "lc_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LC Point Created") except:

print ("LC Point Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - LC Poly print ("Creating Summary Table for LC Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LC/lc_poly_shp", "lc_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LC Poly Created") except:

print ("LC Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - LF Break print ("Creating Summary Table for LF Break") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LF/lf_break_shp", "lf_break.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LF Break Created") except:

print ("LF Break Summary Table process failed, check syntax and parameters.")

Page

36

Practicum Project

December 13, 2013

#Execute Summary Statistics - LF Line print ("Creating Summary Table for LF Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LF/lf_line_shp", "lf_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LF Line Created") except:

print ("LF Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - LF Spot print ("Creating Summary Table for LF Spot") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/LF/lf_spot_shp", "lf_spot.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for LF Spot Created") except:

print ("LF Spot Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSRN Distrib print ("Creating Summary Table for NSRN Distrib") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/RR/nsrn_distrib_shp", "nsrn_distrib.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSRN Distrib Created") except:

print ("NSRN Distrib Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - RR Line print ("Creating Summary Table for RR Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/RR/rr_line_shp", "rr_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for RR Line Created") except:

print ("RR Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - RR Point print ("Creating Summary Table for RR Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/RR/rr_point_shp", "rr_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for RR Point Created") except:

print ("RR Point Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - RR Poly print ("Creating Summary Table for RR Poly") try:

Page

37

Practicum Project

December 13, 2013

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/RR/rr_poly_shp", "rr_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for RR Poly Created") except:

print ("RR Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - ST Line print ("Creating Summary Table for ST Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/ST/st_line_shp", "st_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for ST Line Created") except:

print ("ST Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - ST Point print ("Creating Summary Table for ST Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/ST/st_point_shp", "st_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for ST Point Created") except:

print ("ST Point Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - ST Poly print ("Creating Summary Table for ST Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/ST/st_poly_shp", "st_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for ST Poly Created") except:

print ("ST Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - UT Line print ("Creating Summary Table for UT Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/UT/ut_line_shp", "ut_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for UT Line Created") except:

print ("UT Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - UT Point print ("Creating Summary Table for UT Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/UT/ut_point_shp", "ut_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for UT Point Created") except:

print ("UT Point Summary Table process failed, check syntax and parameters.")

Page

38

Practicum Project

December 13, 2013

#Execute Summary Statistics - UT Poly print ("Creating Summary Table for UT Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/UT/ut_poly_shp", "ut_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for UT Poly Created") except:

print ("UT Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSHN Lake Poly print ("Creating Summary Table for NSHN Lake Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/WA/nshn_lake_poly_shp", "nshn_lake_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSHN Lake Poly Created") except:

print ("NSHN Lake Poly Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSHN WA Cent print ("Creating Summary Table for NSHN WA Cent") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/WA/nshn_wa_cent_shp", "nshn_wa_cent.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSHN WA Cent Created") except:

print ("NSHN WA Cent Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSHN WA Line print ("Creating Summary Table for NSHN WA Line") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/WA/nshn_wa_line_shp", "nshn_wa_line.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSHN WA Line Created") except:

print ("NSHN WA Line Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSHN WA Point print ("Creating Summary Table for NSHN WA Point") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/WA/nshn_wa_point_shp", "nshn_wa_point.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSHN WA Point Created") except:

print ("NSHN WA Point Summary Table process failed, check syntax and parameters.")

#Execute Summary Statistics - NSHN WA Poly

Page

39

Practicum Project

December 13, 2013

print ("Creating Summary Table for NSHN WA Poly") try:

arcpy.Statistics_analysis("D:/GISD3000_GIS_Practicum/Lab2Python/fGDB.gd

b/WA/nshn_wa_poly_shp", "nshn_wa_poly.dbf", [["FEAT_CODE", "FIRST"]], "FEAT_CODE") print ("Summary Table for NSHN WA Poly Created") except:

print ("NSHN WA Poly Summary Table process failed, check syntax and parameters.")

#This script is created by Bronwyn Fleet-Pardy

#Calculating the Fields for Subtype # Execute Calculate Field - BL print ("Apply the Subtype value of 1 to the BL Feature Classes") total = 1 counter = 0 while counter <= total:

arcpy.CalculateField_management (listBL [counter], "Subtype", "1",

"VB") counter = counter + 1 print ("Calculating the Field for the BL Feature Classes executed")

# Execute Calculate Field - DA print ("Apply the Subtype value of 2 to the DA Feature Class") try:

arcpy.CalculateField_management (listDA, "Subtype", "2", "VB") print ("Calculating the Field for the DA Feature Class executed") except:

print ("Calculating the Field for DA Feature Class failed, check syntax and parameters") # Execute Calculate Field - DL print ("Apply the Subtype value of 3 to the DL Feature Class") try:

arcpy.CalculateField_management (listDL, "Subtype", "3", "VB") print ("Calculating the Field for the DL Feature Class executed") except:

print ("Calculating the Field for the DL Feature Class failed, check syntax and parameters")

# Execute Calculate Field - LC print ("Apply the Subtype value of 4 to the LC Feature Classes") total = 2 counter = 0 while counter <= total:

arcpy.CalculateField_management (listLC [counter], "Subtype", "4",

"VB") counter = counter + 1 print ("Calculating the Field for the LC Feature Classes executed")

# Execute Calculate Field - LF print ("Apply the Subtype value of 5 to the LF Feature Classes") total = 2 counter = 0 while counter <= total:

Page

40

Practicum Project

December 13, 2013

arcpy.CalculateField_management (listLF [counter], "Subtype", "5", "VB") counter = counter + 1 print ("Calculating the Field for the LF Feature Classes executed")

# Execute Calculate Field - RR print ("Apply the Subtype value of 6 to the RR Feature Classes") total = 3 counter = 0 while counter <= total:

arcpy.CalculateField_management (listRR [counter], "Subtype", "6",

"VB") counter = counter + 1 print ("Calculating the Field for the RR Feature Classes executed")

# Execute Calculate Field - ST print ("Apply the Subtype value of 7 to the ST Feature Classes") total = 2 counter = 0 while counter <= total:

arcpy.CalculateField_management (listST [counter], "Subtype", "7",

"VB") counter = counter + 1 print ("Calculating the Field for the ST Feature Classes executed")

# Execute Calculate Field - UT print ("Apply the Subtype value of 8 to the UT Feature Classes") total = 2 counter = 0 while counter <= total:

arcpy.CalculateField_management (listUT [counter], "Subtype", "8",

"VB") counter = counter + 1 print ("Calculating the Field for the UT Feature Classes executed")

# Execute Calculate Field - WA print ("Apply the Subtype value of 9 to the WA Feature Classes") total = 4 counter = 0 while counter <= total:

arcpy.CalculateField_management (listWA [counter], "Subtype", "9",

"VB") counter = counter + 1 print ("Calculating the Field for the WA Feature Classes executed")

#This script is created by Bronwyn Fleet-Pardy

# Process: Set Subtype Field for all Feature Classes print ("Setting Subtype Field to all Feature Classes") total = 24 counter = 0 while counter <= total:

arcpy.SetSubtypeField_management(fcList [counter], "Subtype") counter = counter + 1 print ("Setting Subtype Field to all Feature Classes executed")

Page

41

Practicum Project

December 13, 2013

#Adding Subtype to Feature Classes #Add Subtype to Feature Class BL Point try:

arcpy.AddSubtype_management(bl_point, "1", "Building") print ("Adding Subtype to bl_point feature class executed") except:

print ("Adding Subtype to bl_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class BL Poly try:

arcpy.AddSubtype_management(bl_poly, "1", "Building") print ("Adding Subtype to bl_poly feature class executed") except:

print ("Adding Subtype to bl_poly feature class failed, check syntax and parameters")

#Add Subtype to Feature Class DA Poly try:

arcpy.AddSubtype_management(da_poly, "2", "Designated Area") print ("Adding Subtype to da_poly feature class executed") except:

print ("Adding Subtype to da_poly feature class failed, check syntax and parameters")

#Add Subtype to Feature Class DL Line try:

arcpy.AddSubtype_management(dl_line, "3", "Delimiter Line") print ("Adding Subtype to dl_line feature class executed") except:

print ("Adding Subtype to dl_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class LC Line try:

arcpy.AddSubtype_management(lc_line, "4", "Land Cover") print ("Adding Subtype to lc_line feature class executed") except:

print ("Adding Subtype to lc_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class LC Point try:

arcpy.AddSubtype_management(lc_point, "4", "Land Cover") print ("Adding Subtype to lc_point feature class executed") except:

print ("Adding Subtype to lc_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class LC Poly try:

arcpy.AddSubtype_management(lc_poly, "4", "Land Cover") print ("Adding Subtype to lc_poly feature class executed") except:

print ("Adding Subtype to lc_poly feature class failed, check syntax and parameters")

Page

42

Practicum Project

December 13, 2013

#Add Subtype to Feature Class LF Break try:

arcpy.AddSubtype_management(lf_break, "5", "Land Form") print ("Adding Subtype to lf_break feature class executed") except:

print ("Adding Subtype to lf_break feature class failed, check syntax and parameters")

#Add Subtype to Feature Class LF Line try:

arcpy.AddSubtype_management(lf_line, "5", "Land Form") print ("Adding Subtype to lf_line feature class executed") except:

print ("Adding Subtype to lf_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class LF Spot try:

arcpy.AddSubtype_management(lf_spot, "5", "Land Form") print ("Adding Subtype to lf_spot feature class executed") except:

print ("Adding Subtype to lf_spot feature class failed, check syntax and parameters")

#Add Subtype to Feature Class RR Line try:

arcpy.AddSubtype_management(rr_line, "6", "Road or Rail") print ("Adding Subtype to rr_line feature class executed") except:

print ("Adding Subtype to rr_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class NSRN Distrib try:

arcpy.AddSubtype_management(nsrn_distrib, "6", "Road or Rail") print ("Adding Subtype to nsrn_distrib feature class executed") except:

print ("Adding Subtype to nsrn_distrib feature class failed, check syntax and parameters")

#Add Subtype to Feature Class RR Point try:

arcpy.AddSubtype_management(rr_point, "6", "Road or Rail") print ("Adding Subtype to rr_point feature class executed") except:

print ("Adding Subtype to rr_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class RR Poly try:

arcpy.AddSubtype_management(rr_poly, "6", "Road or Rail") print ("Adding Subtype to rr_poly feature class executed") except:

print ("Adding Subtype to rr_poly feature class failed, check syntax and parameters")

Page

43

Practicum Project

December 13, 2013

#Add Subtype to Feature Class ST Line try:

arcpy.AddSubtype_management(st_line, "7", "Structure") print ("Adding Subtype to st_line feature class executed") except:

print ("Adding Subtype to st_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class ST Point try:

arcpy.AddSubtype_management(st_point, "7", "Structure") print ("Adding Subtype to st_point feature class executed") except:

print ("Adding Subtype to st_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class ST Poly try:

arcpy.AddSubtype_management(st_poly, "7", "Structure") print ("Adding Subtype to st_poly feature class executed") except:

print ("Adding Subtype to st_poly feature class failed, check syntax and parameters")

#Add Subtype to Feature Class UT Line try:

arcpy.AddSubtype_management(ut_line, "8", "Utility") print ("Adding Subtype to ut_line feature class executed") except:

print ("Adding Subtype to ut_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class UT Point try:

arcpy.AddSubtype_management(ut_point, "8", "Utility") print ("Adding Subtype to ut_point feature class executed") except:

print ("Adding Subtype to ut_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class UT Poly

try:

arcpy.AddSubtype_management(ut_poly, "8", "Utility") print ("Adding Subtype to ut_poly feature class executed") except:

print ("Adding Subtype to ut_poly feature class failed, check syntax and parameters")

#Add Subtype to Feature Class NSHN Lake Poly try:

arcpy.AddSubtype_management(nshn_lake_poly, "9", "Hydrography") print ("Adding Subtype to nshn_lake_poly feature class executed") except:

print ("Adding Subtype to nshn_lake_poly feature class failed, check syntax and parameters")

Page

44

Practicum Project

December 13, 2013

#Add Subtype to Feature Class NSHN WA Cent try:

arcpy.AddSubtype_management(nshn_wa_cent, "9", "Hydrography") print ("Adding Subtype to nshn_wa_cent feature class executed") except:

print ("Adding Subtype to nshn_wa_cent feature class failed, check syntax and parameters")

#Add Subtype to Feature Class NSHN WA Line try:

arcpy.AddSubtype_management(nshn_wa_line, "9", "Hydrography") print ("Adding Subtype to nshn_wa_line feature class executed") except:

print ("Adding Subtype to nshn_wa_line feature class failed, check syntax and parameters")

#Add Subtype to Feature Class NSHN WA Point try:

arcpy.AddSubtype_management(nshn_wa_point, "9", "Hydrography") print ("Adding Subtype to nshn_wa_point feature class executed") except:

print ("Adding Subtype to nshn_wa_point feature class failed, check syntax and parameters")

#Add Subtype to Feature Class NSHN WA Poly try:

arcpy.AddSubtype_management(nshn_wa_poly, "9", "Hydrography") print ("Adding Subtype to nshn_wa_poly feature class executed") except:

print ("Adding Subtype to nshn_wa_poly feature class failed, check syntax and parameters")

#This script is created by Bronwyn Fleet-Pardy

#Process: Set Default Subtype #Process: Set Default Subtype for BL Point try:

arcpy.SetDefaultSubtype_management(bl_point, "1") print ("Set Default Subtype for BL Point executed") except:

print ("Set Default Subtype for BL Point failed, check syntax and parameters")

#Process: Set Default Subtype for BL Poly try:

arcpy.SetDefaultSubtype_management(bl_poly, "1") print ("Set Default Subtype for BL Poly executed") except:

print ("Set Default Subtype for BL Poly failed, check syntax and parameters")

#Process: Set Default Subtype for DA Poly try:

arcpy.SetDefaultSubtype_management(da_poly, "2") print ("Set Default Subtype for DA Poly executed")

Page

45

Practicum Project

except:

December 13, 2013

print ("Set Default Subtype for DA Poly failed, check syntax and parameters")

#Process: Set Default Subtype for DL Line try:

arcpy.SetDefaultSubtype_management(dl_line, "3") print ("Set Default Subtype for DL Line executed") except:

print ("Set Default Subtype for DL Line failed, check syntax and parameters")

#Process: Set Default Subtype for LC Line try:

arcpy.SetDefaultSubtype_management(lc_line, "4") print ("Set Default Subtype for LC Line executed") except:

print ("Set Default Subtype for LC Line failed, check syntax and parameters")

#Process: Set Default Subtype for LC Point try:

arcpy.SetDefaultSubtype_management(lc_point, "4") print ("Set Default Subtype for LC Point executed") except:

print ("Set Default Subtype for LC Point failed, check syntax and parameters")

#Process: Set Default Subtype for LC Poly try:

arcpy.SetDefaultSubtype_management(lc_poly, "4") print ("Set Default Subtype for LC Poly executed") except:

print ("Set Default Subtype for LC Poly failed, check syntax and parameters")

#Process: Set Default Subtype for LF Break try:

arcpy.SetDefaultSubtype_management(lf_break, "5") print ("Set Default Subtype for LF Break executed") except:

print ("Set Default Subtype for LF Break failed, check syntax and parameters")

#Process: Set Default Subtype for LF Line try:

arcpy.SetDefaultSubtype_management(lf_line, "5"