We have investigated varying data types of spatial features and the different descriptive formats that relate to these features. There is a pattern of following information (or in this case digital data) from file types and where they are located through to managing layers in our software view (i.e. workspace canvas).
Files located on the server with GIS set (QGIS) in Triplets (or more). We can load shape files, as well as a few others directly into QGIS. We should always be careful not to separate any of the other files associated with the *.shp files.
Fig 2: Raw data imports – Files to Layers
“CTNAME”,”Census tract name”
EVENT THEME SECTION
The above file (or a cleaned version of it) can be used to create a data layer in QGIS. It then can be saved as a shape file. Other spatial layers can be added to created maps or perform queries.
Fig 3: Spatial Data Layers and Feature Types
These data layers are made up of (or contain features) that represent geographical features. These features are divided into feature types (such as points, lines or polygons).
Fig 4: Theftsfrom Table – unique identifiers and XY valus
The above table is associated with a spatial data layer derived from the combination of a Postal Code lookup table and a crime spreadsheet file. This table contains attribute information that can be connected, through a Unique ID (unique feature identifier), to other attribute tables. It is also important not to mix up the attributes (rearrange the contents of each row) so a connection to the individual spatial is maintained. The connecting ID for the feature and the table entry is hidden so all joins should be carried out in QGIS (we will discuss this as we perform more table joins in tutorials and labs).
The above table has an item (column name) called UID.
if we look inside a file called postal.meta that is associated with a shape file called postal.shp we might see this in it content:
Fig 5: metadata from postal codes
File creation date: January 12, 2005
Last edited January 17, 2005
original file created: Scott Emmons , GIS lab UNBC
last edited: Scott Emmons, GIS lab UNBC
“POSTCODE”,”Postal Code”, char
“CTNAME”,”Census tract name”, char
comments: This was a file created for generating a point layer describing postal codes for Prince George, B.C. Canada.
It is important to create and maintain “*.meta” files (or something like them) to establish a greater knowledge of where and who created the data you and others are to work with.
Can you think of other pieces of information that would be usefull in this meta file?
In the last lab we were presented with methods for creating features in QGIS. We could use the drawing tools that come with the software or we could use extensions designed for completing different tasks.
- We saw that we can clean up a text file we download from the web so it can be used in a GIS.
- We also repaired line layers using the NWF/DEM extension in order to create polygons.
This method of fixing data such as we did in the last lab is called “building and cleaning”
This terminology refers to the way ArcInfo stores and manipulates spatial layers. This system of data modelling has changed in recent years, but we will still employ many of the methods and terms used for creating and inspecting spatial data.
The following illustration gives some examples of how data that is clean and some that is not.
Fig 6: Cleaning Varying Spatial data errors
In the tutorial we will be learning what data and services are present at the UNBC Library and the Statistics Canada webg site. In the lab we will use some of these data to create linkages to Stats Can boundary files (seeing what problems result from this data manipulation) A web search can be done on spaghetti data, discrete data and building – cleaning GIS data.
In GIS we use Simple Features
Mathematical derivations of geometric features
Geometric objects can be drawn using an endless list of methods. If you are a Math major, you may have spent numerous hours understanding the differnt formulas that define geometric shapes. For instance the shape of an ellipse is defined by:
You can draw and ellipse by setting two points by running your pencil around two points such as:
This is great for math and engineered drawings needing very specific mathematical formulas met. We are not demanding in GIS. Files such as shapefiles do not understand these type of formulas. Drawings created through Computer Aided Drawing (CAD) do make use of these formulas, but when they are converted to common GIS formats such as shapefiles – all this lost. The features created using formulas are generalized to Simple Features. This is how most GIS data is stored.
Simple features are drawn – very simply. Sounds kind of boring, and it is – but as you progress through the course, you will see how useful this approach is. This does not mean that we do not have plenty of issues dealing with simple geometries, but it does allow us to create features very easily. Below is a series of how features area created.
With this method we create a series of points that can be used to create a set of points. We can also use a series of points to create a line (not the math definition), and for a polygon as well. If you think of this in combination of using clean and built spatial features – it will all start to make sense.
A couple of links – tough going though