Preamble: “Not only is it easy to lie with maps, it’s ...

10
Exercise 3: Mapping Areal Features Sample of the map we will be making: Preamble: “Not only is it easy to lie with maps, it’s essential. To portray meaningful relationships…a map must distort reality.” (Monmonier 1991: 1) Mapping is an inherently political process (Crampton 2010); the map we’re making in this exercise has many elements that are problematic and highlight this. Given time, we can discuss these issues (but we want to make sure there is time for working with your own data). However, for our purposes it is useful to demonstrate skills that you can use in other GIS projects. Purpose of Exercise: -Using Geoprocessing Tools (Clipping) to create a map from larger datasets to meet other needs -Reprojecting data to make a region-appropriate map -Manipulating/Editing Attribute Tables and using expressions to quickly sort Attribute Table data (-Evaluating data and considering the political implications of our maps: understanding data sources, biases or other problems when using others’ data)

Transcript of Preamble: “Not only is it easy to lie with maps, it’s ...

Page 1: Preamble: “Not only is it easy to lie with maps, it’s ...

Exercise 3: Mapping Areal Features Sample of the map we will be making:

Preamble: “Not only is it easy to lie with maps, it’s essential. To portray meaningful relationships…a map must distort reality.” (Monmonier 1991: 1) Mapping is an inherently political process (Crampton 2010); the map we’re making in this exercise has many elements that are problematic and highlight this. Given time, we can discuss these issues (but we want to make sure there is time for working with your own data). However, for our purposes it is useful to demonstrate skills that you can use in other GIS projects. Purpose of Exercise: -Using Geoprocessing Tools (Clipping) to create a map from larger datasets to meet other needs -Reprojecting data to make a region-appropriate map -Manipulating/Editing Attribute Tables and using expressions to quickly sort Attribute Table data (-Evaluating data and considering the political implications of our maps: understanding data sources, biases or other problems when using others’ data)

Page 2: Preamble: “Not only is it easy to lie with maps, it’s ...

Preliminaries: Gathering our data and Setting up our new project 1. In the folder where we’re storing our QGIS project files, we’ll want to make sure that we have downloaded and extracted the following files from the course website: us_nal_areal_data.zip, WALS_US_Data.zip, and cb_2016_us_state_500k.zip. 2. In QGIS we will want to start a new project (blank map). 3, In this exercise we will be purposefully changing our projection system. To begin, make sure that you are in the WGS 84 (EPSG: 4326) projection and that you have OTF ‘on the fly’ projection enabled.

Adding and Analyzing our data 1. First we will adding the cb_2016_us_state_500k.shp file to our map. This will serve as the basis for our map. N.B.: In this exercise we will be editing our shapefiles. The result of this is that the file we started with will be permanently altered. This is why it is often wise to save your original zip file. You can always duplicate and rename shapefiles in future projects: just remember that QGIS stores your edits in the edited file, and can therefore cause data loss problems. (This is not a problem for “clipped” files, but it is if you edit the attribute table.) 2. Once you’ve added the shapefile, you should have a workspace like this (zoom level will vary):

Page 3: Preamble: “Not only is it easy to lie with maps, it’s ...

3. Let’s say we’re not interested in mapping the entire U.S., but only a few states. We can edit our map to only contain the states that we’re interested in mapping. For our map, we only want Utah and the surrounding states: Nevada, Idaho, Wyoming, Colorado, New Mexico, and Arizona. We therefore need to remove all other states. 4. To begin, open the Attribute Table for our state map layer by right-clicking (shift-click for Macs) on the layer entry:

5. You should now be in the Attribute Table. We will need to turn editing on by clicking the pencil in the upper-right corner:

Page 4: Preamble: “Not only is it easy to lie with maps, it’s ...

6. We now want to select and remove all of the states that we won’t be including on our map. We can do this manually (i.e., go through one by one and remove the states), but this would be time consuming. Instead, we are going to use an expression to remove all the states that we don’t want. To do this, click on “Select features using an expression”:

7. This will open up the field calculator, where we can use regular expressions and/or sql query syntax to select features from our shapefile. We’ll enter an sql query string to select all the states that are not of interest to us: "STUSPS" not in ('AZ', 'CO', 'ID', 'NM', 'NV', 'UT', 'WY')

Page 5: Preamble: “Not only is it easy to lie with maps, it’s ...

8. We can now select and delete all unnecessary areas:

9. Note that your map will still be in editing mode even after deleting these entries and closing the Attribute Table. Disable editing for now by clicking the pencil icon. When prompted, agree to save your edits. (This is the point at which your shapefile becomes permanently altered.) 10. Next, we’ll add our linguistic data: add us_nal_areal_data.shp to the project:

Page 6: Preamble: “Not only is it easy to lie with maps, it’s ...

11. We’ve decided that we only want to map data for our seven states; however, the data we just added is beyond the borders of those states and would not cleanly break down into the same map. To map the new data to only our seven states, we will “clip” the new shapefile to our custom seven-state shapefile. Getting what you pay for: There is a fairly common bug that can occur here, and unfortunately there are several ways of fixing it depending on how things broke. If, going into Step 12, you find that your menu is missing the geoprocessing tools, let us know and we’ll attempt to fix the issue. If we can’t do it without a reinstall, you can download the clipped.zip file from the course website and use that for making this map (it will function just like adding another shapefile layer). 12. To clip our file, we will begin by going to the Vector menu and selecting Geoprocessing Tools:

13. In the clip menu, we will select our data. The input layer at the top needs to be the file that we want to clip (us_nal_areal_data). The clip layer is the smaller area that we are wanting to map. We can give a name to the “clipping” and save it as a shapefile if we so desire:

Page 7: Preamble: “Not only is it easy to lie with maps, it’s ...

14. We now have a map of only the areas we are interested in. You can turn off the us_nal_areal_data layer and set the fill of the cb_2016_us_state_500k fill to transparent:

15. Reorder the layers and zoom to the Clipped layer to get the following map:

Page 8: Preamble: “Not only is it easy to lie with maps, it’s ...

16. One more step before we start analyzing the data: let’s change the projection so that we are “centering” our map on Utah. For this, we will use the NADS 83 “Utah Central”/EPSG 3675 projection:

17. Now that we have an area-appropriate map, let’s map the data from us_nal_areal_data file.

Page 9: Preamble: “Not only is it easy to lie with maps, it’s ...

18. There are many ways of approaching our data at this point; the easiest is to access the Attribute Table and look at what sort of data is contained in the file. However, you may have some difficulty decoding this data unless you are familiar with how WALS codes different features: shapefiles are limited to ten characters for column names, which can result in short, incomplete, or difficult to decipher column names (csv files in GIS programs do not have this issue, nor do other geographic data storage formats). You can use WALS (http://wals.info) to help in decoding what the numbers in the column headers mean. You are also free to try different columns to map. The remainder of this guide reflects one possibility for mapping the data. 19. We will be mapping the order of Subject and Verb: column heading 82A. As in previous exercises, we will be sorting the data in the Properties of the data layer (clipped):

Page 10: Preamble: “Not only is it easy to lie with maps, it’s ...

20. Note that we will want to make some adjustments to colors and legend entries:

21. We now have an area map that we are ready to export:

22. As before, we will open a new Print Composer and stylize our map. We will want to add a legend and a title. We can also consider adding attribution for our data: WALS, the U.S. Census Bureau, and Native Languages.Org.