Home
Introduction to GIS Using Open Source Software
Contents
1. l 0 ox Close 5 Remove tracts outside NYC from selection 2 Zoom in to the map so that you can see all of the tracts around the boundary of the city Select the Tracts layer in the ML Hit the M3 select features button While holding down the CTRL key click on each of the tracts that are outside of the dark NYC boundary one by one to unselect each one If you unselect a tract by mistake just click it again to re select it If you inadvertently unselect all of the tracts by letting go of the CTRL key and selecting a feature you ll have to redo the previous step with the Select by Location tool to to reselect all of them 6 Save selection as new layer Select the tracts layer in the ML Right click and choose the Save As option In the Save vector layer menu save the new layer as an ESRI shapefile Browse and save it in your part 3 folder as TRACTS_NYC Notice that the new file will be given the same CRS as the current layer which is in NAD 83 New F Donnelly Baruch CUNY 2015 29 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS York Long Island Make sure to check these two boxes Save only selected features and Add saved file to map Hit OK P Z Save vector layer as Format ESRI Shapefile Save as jis_prac gis_prac_data part3 tracts_nyc shp CRS Layer CRS NAD83 New York Long Island ftUS Change Encoding System X Save only selected features
2. 84 000000000 45 899999999 177708 00000 65460 000000 8 152 155 00000000 47 000000000 30 300000000 99219 000000 93187 000000 8 275 6471 0000000 1753 0000000 27 100000000 122278 00000 27389 000000 8 38 1806 0000000 664 00000000 36 799999999 133889 00000 19597 000000 Ta 94 1992 0000000 617 00000000 31 000000000 85938 000000 19868 000000 7 w 4 al 5 Build an advanced query Back in the map view hit the 2 the Zoom to Full Extent button Select the TRACTS DATA COUNT layer in the ML to activate it Then hit the Expression button In the Function list scroll down to Fields and Values Expand that menu and double click on per_fem to add it to the Expression builder In the Expression box type gt 24 6 to select all values that are greater than or equal to 24 6 Next type the word AND Double click on medinc to add it to the Expression box Type lt 100000 in the expression do NOT use any commas to select areas with median income less than that amount Lastly add another AND statement with PNTCNT to the expression and indicate lt 3 Your final statement should read per_fem gt 24 6 AND medinc lt 100000 AND PNTCNT lt 3 K Select by expression tracts_data_count Expression Function Editor Expression Functions lat ca a A Search per fem gt 24 6 AND INTPTLAT medinc lt 100000 AND INTPTLON PNTCNT l
3. 4 3 More Geoprocessing and Joiningl 68 TR o ETA 69 A32 COMMEN aaa AA aaa 70 SS EREGDRE SAA EAD PREYS DRED RAR AA 70 44 Classifying and Symbolizing Data 2 e 71 11 4 4 COMEDY e s soe 48 4544846 E RE SR Se ee EEE SHES HEED 73 asar AA anes 73 ao ro aa asa EEE EES AR 74 LAN Desi pninge MADE 5 ria Ee Ee AAA AAA ARA ee 75 Darro orcas ara AA AS 75 A52 COMMEN 44 4 eae oo eS Oe ds ee Ao oe eee eS ae eee 79 QGIS Map Composer Scale Bars and Other Details 79 pie Oe eee Se ee ae oe Bare eee oy oe ee ee eee ee 80 aaa he dada utente saeearegen eee oe ae 81 4 6 Adding Labels ic 4 4 4 22484484 oe Kae Re ERDAS ER EES OE OE REE EES 81 EOL SCORECARD AA 81 492 COMIMENVATY lt 2 amp por ve WG 6 id o RE A E A 84 Labeling in QGIS v 64 4 a4 Phu ae whe ae hea EERE KOE SAME SRSA 84 Thematic Maps and Symbols ae 85 4 7 Considerations and Next Steps 0 aaa 85 5 Going Further 87 A Todan Dalla a a ok ee a ee at hk ee Oe ae AAA ee A a E S 87 Appendices 94 A QGIS Desktop Browser 94 AA UCD aaa eke ae ee Ae ee ee oe eee a ee AAA 94 B Tabular Data DBF Files 96 98 as 98 ea 99 ASA 99 dara aaa ORE ee sab 100 101 111 Introduction Frank Donnelly Geospatial Data Librarian Baruch College CUNY francis donnelly baruch cuny edu Last Updated July 30th 2015 6th ed Introduction
4. Output Shapefile data part3 tracts_data_count shp Browse X Add result to canvas 0 OK Close l 3 Swap your layers Select the TRACTS_NYC_DATA layer in the ML right click and remove it Drag the new TRACTS_DATA_COUNT layer to the bottom of the ML just above the Boroucus layer Don t worry about symbolizing the new layer 4 View the table for the new layer Select TRACTS para counr in the ML right click and open the attribute table Scroll the table all the way to the right You ll see the new PNTCNT field which shows the number of coffee shops in each tract Click on the PNTCNT column heading to sort the table by that field from low to high and click again to sort from high to low You ll see there are a number of tracts that have many coffee shops but the distribution tapers off rather quickly particularly once we get past three coffee shops per tract So for our basic example we ll say that if a tract has three or more coffee shops we ll omit it from consideration Close the attribute table F Donnelly Baruch CUNY 2015 47 CC BY NC ND 4 0 3 5 RUNNING STATISTICS AND QUERYING ATTRIBUTES CHAPTER 3 GEOGRAPHIC ANALYSIS Sheet1_tot Sheet1_fem Sheet1_per Sheet1_med Sheet1_moe PNTCNT S 268 73 000000000 28 000000000 38 399999999 38281 000000 50787 000000 ul 31 1116 0000000 316 00000000 28 299999999 137614 00000 48191 000000 9 30 183 00000000
5. This tutorial was created to accompany the GIS Practicum a day long workshop offered by the Newman Library at Baruch College CUNY that introduces participants to geographic information systems GIS using the open source software QGIS The practicum introduces GIS as a concept for envisioning information and as a tool for conducting geographic analyses and creating maps Participants learn how to navigate a GIS interface how to prepare layers and conduct a basic geographic analysis and how to create thematic maps This tutorial was written using QGIS version 2 8 Wien a cross platform Windows Mac Linux desktop GIS soft ware package You can download the software and user manual from the QGIS website at http www qgis org Given differences between versions it s best to use this tutorial with version 2 8 Wien although much of the material will apply to all 2 x versions of QGIS Quick links for downloading both 2 8 and the data used for the tutorial are available at https www baruch cuny edu confluence display geoportal GIS Practicum Once you download and unzip the data file you ll see that the data is separated into different folders for each part of the tutorial Anyone is welcome to use this document under a Creative Commons Attribution Noncommercial No Derivative Works 4 0 International License CC BY NC ND 4 0 http creativecommons org licenses by nc nd 4 0 for personal or classroom use e You MUST attribute the aut
6. add new map button in the toolbar Then draw a box on the map canvas click on upper left hand corner hold down left mouse button drag box leaving an even amount of space on each side so there is a gap between the map and the edge of the canvas If you don t get it right on the first try you can always hover over an edge of the map hold down the left mouse and drag the edge to change the size Or to shift the entire map on the page use the select move button This button moves the entire map box To shift the geography inside the map box use the adjacent move item button Move the map around so that the lower 48 states are roughly centered in the box With the move item button selected you can also change the zoom of the map by using the mouse wheel or by clicking on the Item properties tab on the right and experimenting with the scale under the Main properties menu a lower number will zoom in and a higher number will zoom out 4 Experiment with the canvas zoom The regular 4 zoom buttons on the toolbar will NOT effect the zoom of the geography these zoom buttons just zoom you closer and further from the map canvas similar to taking a piece of paper and holding it closer or further from your face Experiment with them and see If your map looks blurry from resizing a window just hit the refresh button When you re finished with the map selected go to the Item properties tab and check the box beside Frame to turn the map fr
7. 2164 filtered 2164 selected 0 X 4 amp BERS POE a STATEFP COUNTYFP TRACTCE GEOID NAME NAMELSAD 712 136 005 1000100 1 Census Tract 1 397 136 005 000200 3600500020 2 Census Tract 2 669 36 005 000400 OOO 4 Census Tract 4 648 136 005 001600 36005001600 16 Census Tract 16 409 36 005 001900 36005001900 19 Census Tract 19 667 36 005 002000 36005002000 20 Census Tract 20 005 002300 36005002300 23 Census Tract 23 005 002400 36005002400 24 Census Tract 24 005 002500 36005002500 25 Census Tract 25 4 Add Excel file to the project The QGIS browser isn t configured to display Excel files so we ll have to use the Add vector data button In the Add vector layer menu browse to your part 3 folder Change the file type drop down from ESRI Shapefiles to All Files Click on p Emoc_pata xts to select it then hit Open and Open again on the menu to add it It should appear in the ML as Sheet1 which is the first and only sheet in our workbook that has data You can select it in the ML and hit the open table button to verify that the table displays correctly 5 Join data table to shapefile Close the table and double click on the Tracts Nyc tann layer to open its properties menu Hit the Joins tab Hit the green plus button to add a join The join layer will be the data table SHEET1 The Join field in that table is id The Target field in the tract layer is GEOID At the bottom of the menu check t
8. Change the generic Legend title to Citizens who Voted In the Legend items box uncheck the Auto update box Select the Vote table and hit the red minus sign to remove it Then select the stares_1cc layer hit the 4 edit legend button and change the name to Percent Total Then select the Percent Total title and hit the Sigma button to turn the feature count off Then under Fonts change the Title font from 16 to 14 Scroll down to the bottom of the Item properties menu and turn the Frame on The final step is to move the legend to an ideal position in the corner of the map which may require you to shift the map around a bit Composition Item properties Atlas generation Item properties Legend w Main properties Title Citizens who Voted Title alignment Left v Map Map 2 z Wrap text on v Legend items Auto update Update all amp Percent Total 47 8 55 9 55 9 61 9 61 9 67 6 67 6 75 9 iaa iv Add a title Hit the s add label button Click on the top of the map and a generic label is added In the Main properties under the Item properties tab change the default QGIS label to Voter Participation in the 2012 Election Under the Appearance menu change the font to 18 using the font button Click on the label in the map and using the select move button move the label to the top center of the map and expand the size of the label box so the title appears on one line Add a label with sourc
9. In this tutorial you ve learned what GIS is what it looks like and generally how it works You ve learned how to work with vector based GIS data to do some basic geoprocessing and analysis and you ve learned the basics of thematic mapping and map design Here are some things that we didn t cover that you may wish to explore next Geodatabases Instead of storing all of your features in individual shapefiles and your attribute data in several spreadsheets store everything in a single database file Use the database software to organize your data to run spatial and non spatial queries QGIS can directly connect to the desktop Spatialite database or the network based PostGIS database Download the NYC Geodatabase and follow the Spatialite tutorial here http www baruch cuny edu geoportal nyc_gdb Working with rasters The GDAL plugin allows you to do more interesting things with rasters Download the Working with Raster Data in QGIS tutorial It focuses on working with digital elevation models and includes downloading tiling and warping re projecting DEMs and DRGs and creating hillshades and contour lines http www baruch cuny edu geoportal practicum raster Creating and editing vector layers QGIS has an entire suite of tools that allow you to edit files point by point line by line feature by feature and to create files from scratch Georeferencing The georeferencing plugin gives you the ability to take non GIS raster file
10. NAD 83 to a PCS that s appropriate for thematic mapping F Donnelly Baruch CUNY 2015 65 CC BY NC ND 4 0 4 2 TRANSFORMING MAP PROJECTIONS II CHAPTER 4 THEMATIC MAPPING 1 Create a new project Open QGIS to an empty blank project using the New project button Hit the Save as button Browse to your data folder for part 4 and save the project as part4 acs We ll be working with this project for the rest of this chapter Go to Project gt Project Properties gt CRS tab and insure that on the fly projection is turned off 2 Add the states shapefile Tab to the browser and add the Gz_2010_Us_040_00_20m shapefile to the project Tab back to the Layers menu Note that beside the coordinates display which are in degrees the EPSG code is 4269 Hover over it and you ll see the CRS is NAD 83 Save your project Layers ex F eg X F gz 2010 us 040 00 20m Browser Layers 9 Coordinate 95 1 6 0 Scale 1 60 400 413 X Render EPsG 4269 Ey A Current CRS NAD83 3 Transform the projection Let s transform the layer to something that s more suitable for a thematic map Select the states layer in the ML Right click and hit Save As Hit the globe CRS button beside the CRS entry In the CRS Selector window type in North America Lambert in the Filter Box at the top This filters the entire CRS database by name and we ll see North America Lambert Conformal Conic EPSG 102009 appear in the bottom windo
11. Skip attribute creation X Add saved file to map Symbology export No symbology Scale 1 50000 7 Add new layer to map If you checked the Add saved file to map check box in the last step the new file should be added to our map If you neglected to do this or if you ever forget in the future the file has still been created you just have to manually add it to the project To do this you would tab over from the layers menu to the browser and drill down to the part 3 folder Hit the refresh button just above the browser to update it You should then see the new file Tracts Nyc there Drag the new file into the window to add it or select it right click and Add Layer Then flip back to the layers view J gis_prac_data E de part2 E de part3 demog_data dbf gt nyc_coffee bd gt nym_water shp C t1_2012_36_tract_nysp shp El Ly part4 8 Tidy up your layers As we create new layers we can remove the old ones We re finished with the ORIGINAL TRACTS layer for NY state and the B_BOUNDARY layer Select each one in the ML right click and remove it Drag the Tracts For NYC to the bottom of the ML Save your project at this point E Donnelly Baruch CUNY 2015 30 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS 9 Compare boroughs to tracts Move the BorouGHs layer so it is above the Tracts layer and check it to turn it on This illustrates that the census tracts cover both la
12. copyright and use restrictions You ll want to check the metadata to verify that the data is going to meet your needs and that you can use it for your intended purpose For example you wouldn t want to use a generalized boundary file if you re mapping at a large local scale and if you are going to use the data for a commercial purpose you need to verify that that s permitted In any event you should cite the source of your data in any maps tables or reports you create from it If you are looking for a particular GIS file and it s provided by several sources which source should you use For example if we wanted census tracts for a particular city we could download them from the city s GIS page from a state based site from a college or university repository or from the Census Bureau itself via the TIGER page or the generalized boundary page To answer this question you ll have to examine the download page and even download the files to view them and their metadata Here are some things to consider e How are the files packaged for download Do I have to download them one place at a time or could I get the entire area in one download E Donnelly Baruch CUNY 2015 88 CC BY NC ND 4 0 5 2 DATA SOURCES CHAPTER 5 GOING FURTHER e Who created the files originally Is it better to go with the original source Or has a secondary source added some value that makes their files more desirable Can I trust the source Is there metadat
13. lon_0 0 x_0 0 y_0 0 datum WGS84 units m no_defs 5 Reset the CRS in the window In this case seemingly nothing has happened Our new countries layer in the Mollweide projection looks exactly the same as our WGS 84 countries layer and in the lower right hand corner the EPSG Code is still 4326 for WGS 84 Why is this By default the QGIS map window takes the CRS of the first layer that s added to the project and will attempt to reproject all layers on the fly so if they are in a different CRS they will draw together To overcome this select couNTRIES_ MOL in the ML right click and choose Set Project CRS from Layer This renders our Mollweide file correctly and changes the window to EPSG 54009 note the updated EPSG number in the lower right hand corner It also attempts unsuccessfully to render our old WGS 84 layer on the fly as Mollweide Layers E x ca Y fe La x countries mol Browser Layers Coordinate 16743676 1077764 Scale 289 228 450 X Render EP nn gt Current CRS World_Mollweide 6 Disable on the fly projection Generally speaking it s a bad idea to have On the fly projection enabled so we ll turn it off for this project First select the original NE_50M_ADMIN_O_COUNTRIES layer in the ML right click and F Donnelly Baruch CUNY 2015 59 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING remove it Then go to Project gt Project Properties gt CRS tab Uncheck t
14. positive values In QGIS you have the ability to adjust classes or create manual classes To do this you classify the data using one of the standard methods in the Style tab for the layer then select the class that you want to change and double click on the range You ll be able to type the values in by hand Color schemes for displaying quantitative values on choropleth shaded area maps should show a logical progres sion of color values The progression from light to dark helps convey the change in data values from low to high and most map readers can infer this without even looking at the map legend Creating a mixed fruit salad of colors will defeat this natural inference and will confuse the map reader so don t do it When comparing qualitative values categorical data instead of ranges of values a map should use colors that reflect those values For example it makes sense to use reds and blues to show which political party a state voted for as these colors have become associated with the US political process Without even looking at a legend or description the average American will instantly understand what this map is about Depicting the same data with greens and yellows doesn t make much sense and results in confusion F Donnelly Baruch CUNY 2015 73 CC BY NC ND 4 0 4 4 CLASSIFYING AND SYMBOLIZING DATA CHAPTER 4 THEMATIC MAPPING While we re not considering it for this exercise the unit of geography used to map phenomena c
15. 2015 55 CC BY NC ND 4 0 3 8 CONSIDERATIONS AND NEXT STEPS CHAPTER 3 GEOGRAPHIC ANALYSIS error Second it s not always necessary to create a new file with every single processing step Some menus will give you the option to select features or perform operations on features that are ALREADY selected This allows you to work with just the features you need from one layer to create a new one skipping the interim step of creating a new shapefile of just the features you want to work with When we ve created new layers we have used underscores instead of spaces when naming files i e TRACTS_NYC_DATA SHP When naming files it s best practice to use underscores instead of spaces and to avoid using any punctuation in file names This helps to insure compatibility of data across operating systems and to prevent possible errors when loading or reading data in the software You should follow the same rules when creating folders to store data The name of your file should reflect what it contains you could include the geographic area it covers the type of feature and possibly a date or number to indicate different iterations of the data The QGIS Browser makes managing and working with your files a bit easier It filters files in your folders so that only GIS usable files are visible It also collapses shapefiles to single entries so that it s easier to see what you have In addition to the internal Browser in QGIS Desktop there is also a stand al
16. 6 ADDING LABELS CHAPTER 4 THEMATIC MAPPING 5 Move the label for Florida With srares_1cc selected in the ML right click on it and hit the 4 edit button to enter an edit mode You ll see each state outlined with little x s these are the individual nodes that make up the points of each polygon and this is your clue that you re in an editing mode You ll also see that the move label button on the toolbar is now active Hit the button and you ll see a crosshairs as you move across the map Adjust your map so that Florida FL is visible and centered Move the crosshairs over the FL label hold down the left mouse button drag the label to the center of the state and release 6 Adjust additional labels Do the same to move the label in nearby Louisiana LA Then use the W pan tool to move to the northeastern US then reactive the move label button Move the label for Maryland MD to the north and the label for DC to the south so that both will be visible The labels aren t going to look right at this scale so zoom out back to the continental US to make sure the labels look OK at that scale Lastly adjust the label for Massachusetts MA by moving it up a little so that the label for Rhode Island RI will draw Once you re satisfied hit the edit button for the layer to stop editing and save your edits You may have to enter the edit mode move labels and exit a few times until you get the labels right as it may be difficult to
17. 9 Union D Symetrical Difference pw Clip Ey Difference D Dissolve P Eliminate Sliver Polygons Convex Hulls creates the smallest possible convex polygon enclosing a group of objects e Buffers creates an equal zone around specific features at a specified distance Intersect creates new layer based on the area of overlap of two layers e Union melds two layers together into one while preserving features and attributes of both e Symmetrical Difference creates new layer based on areas of two layers that do not overlap e Clip cuts a layer based on the boundaries of another layer e Difference subtracts areas of one layer based on the overlap of another layer e Dissolve merges features within a single layer based on common attributes in the attribute table Eliminate Sliver Polygons merges left over or misformed geometry with neighboring features In addition there are also some geoprocessing tools under the Geometry Tools menu in ftools that convert or break polygons apart into simpler features like lines or points and under the Data Management Tools menu for aggregating many shapefiles into one file the opposite of the selection subset process Geoprocessing for raster layers is available through the GDAL plugin Raster menu Lastly several extensive collections of processing tools for both vectors and rasters are available in the Toolbox under the Processing menu 3 3 Joining and Mapping Attribut
18. CITY STATE STCODE CNTYCD 1 416334216 174TH STREET COFFEE SHOP 920 E 174TH ST BRONX NY 36 005 669266520 4 BEAN CAFE 1740 EASTCHESTER RD BRONX NY 36 005 E 414414688 B K COFFY 381 RIDER AVE BRONX NY 36 005 414414684 BJESHKA CAFE 400 E 198TH ST BRONX NY 36 005 238408561 BUS STOP COFFEE SHOP 211 W 231ST ST BRONX NY 36 005 EPPEP 243906328 BUS STOP COFFEE SHOP 885 E GUN HILL RD BRONX NY 36 005 406159423 DADA S COFFEE SHOP 2287 WESTCHESTER AVE BRONX NY 36 a E Donnelly Baruch CUNY 2015 A2 CC BY NC ND 4 0 3 4 PLOTTING COORDINATE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS 4 Specify the coordinate system After you hit OK you ll be prompted to specify what system the coordinates you re plotting are in They re in simple longitude and latitude and we re in North America so we will define them as NAD 83 In the CRS Selector type NAD83 no space in the Filter box Then in the Coordinate Reference System menu at the bottom scroll to the top of the menu The very first record in the list is simple NAD83 EPSG 4269 Select it in the list and hit OK This will plot our points 06 o Coordinate Reference System Selector Specify CRS for layer nyc_coffee Filter NAD83 A Recently used coordinate reference systems Coordinate Reference System Authority ID NAD83 New York Long Islan EPSG 2263 l Ko Coordinate reference systems of the world Hide deprecated CRSs ordina
19. China near the Kyrgyzstan border In a coordinate pair latitude is always the Y coordinate and longitude is the X coordinate Map Projections Most people today would agree that the earth is round Most maps whether they re on paper or a computer screen are flat When you take a three dimensional sphere and flatten it to two dimensions you get fair amount of distortion Imagine removing the peel from an orange and laying it out flat you can t do it without tearing the peel A map projection is a method for taking the three dimensional earth and transforming it to a flat surface For a nice overview visit http www radicalcartography net projectionref Radical Cartography s projection page and note the common projections marked in pink Projections can be classified based on how the grid is applied to the earth s surface a grid laid flat on top azimuthal wrapped as a cone on the top half of the earth conical wrapped around the earth as a cylinder cylindrical etc They can also be organized based on which property they preserve E Donnelly Baruch CUNY 2015 62 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING Area Equal Area areas that are the same size on the globe appear as the same size on a map Examples Mollweide projection for the earth Albers Equal Area for continents Shape Conformal preserves angular relationships and shapes for small to medium areas but distortion
20. Generally features can be displayed and differentiated from each other using text For example the standard cartographic convention for labeling bodies of water is to use an italic font and when possible a dark blue color The size of a label indicates the hierarchy of the feature oceans have larger fonts than seas which have larger fonts then rivers larger than streams etc Land features are labeled in black or anything that isn t blue and are never written in italics Larger features land or water may be written in all capital letters while smaller features are in lower case F Donnelly Baruch CUNY 2015 84 CC BY NC ND 4 0 4 7 CONSIDERATIONS AND NEXT STEPS CHAPTER 4 THEMATIC MAPPING ATLANTI C OCEAN GULF OF MEXICO Lake Ontario Hudson River UNITED STATES NEW JERSEY Philadelphia Trenton Thematic Maps and Symbols In this tutorial we worked through an example for creating a shaded area or choropleth map However there are a number of other techniques that you can use to create a thematic map QGIS also supports graduated symbols for point and line layers where the relative size of the symbol a circle square line or image represents a value if you look at the style tab for a point layer you can change the legend type to graduated symbols If you have a polygon layer that you d rather map as graduated circles instead of shaded areas you have to convert it to a point layer first you can do this under Vector gt Geometry Tool
21. NYC and Long Island area By default all of the Census TIGER shapefiles use the coordinate reference system CRS NAD 83 which is identified with the code EPSG 4269 This is a basic longitude and latitude system that is common throughout North America All of the files in our exercise were originally in NAD 83 and were re projected to NY State Plane Long Island EPSG 2263 We ll discuss and work with coordinate reference systems in Chapter 4 The Census Bureau makes minor updates to boundaries and issues new TIGER files each year but major changes occur at the beginning of each decade as the decennial census is released There are often minor changes to statistical areas like census tracts and ZCTAs within a few years of the decennial release to correct errors but after that these areas are fixed and generally do not change until the next ten year census In contrast updates to legal boundaries like states counties or municipalities are made on an annual basis The TIGER files used in this exercise are from the 2012 TIGER Line Shapefiles which are based on 2010 Census geography Geographic Selection One of the strengths of GIS is the ability to perform spatial queries on features i e select all areas that intersect other areas This is an area where QGIS continues to develop The Select by Location feature of the fTools plugin only allows you to select features that intersect other features and recently they ve added options like border
22. Natural Breaks In the Color ramp drop down select a scheme that has a range of single color values that go from light to dark Hit the Classify button and then hit OK You should now have a choropleth shaded area map that shows the percentage of the total population in our gender and age bracket for each tract classified by natural breaks divides data into categories based on gaps in values We ll discuss color and classification schemes in more detail later on Turn the GREENSPACE and FACILITIES layers on to cover up areas of tracts that are non residential Save your project Y Layer Properties tracts_nyc_data Style E Graduated z Y Style Column per_fem z Labels Symbol I change Classes 5 v Fields Color ramp T source y Invert Mode Natural Breaks Jenks y Rendering Legend Format 1 2 Precision 1 Trim G Display Symbol Values Legend x 0 000 8 000 0 8 O Actions x 8 000 22 400 8 22 s x x x 22 400 27 600 22 28 27 600 35 200 28 35 35 200 66 700 35 67 gt E Joins z Diagrams ES 4 1 Metadata Classify Add class Delete Delete all X Link class boundaries Advanced v 3 3 2 Commentary Census Data The demographic data used in this exercise comes from two US Census Bureau datasets the 2010 Census for data on age and gender and the American Community Survey ACS for data on income Most people are familiar with the ten year census whi
23. Right below the scale in the menu is Map rotation which is currently set to o You can type values here to rotate the items in the map from o to 359 degrees clockwise Since Alaska looks a little skewed since we re using a map projection for the whole continent and AK is on the edge change the rotation to 330 to straighten Alaska out Under Item properties scroll down to the bottom and turn on the Frame for the box Once you re finished repeat the same steps for Hawaii add another map zoom in to focus on the main eight islands rotate it by 320 and turn on the frame Save your project 50 0 00 2 l tems Command history v A E enana nen E E A EE E E E noel E EE ere nen ena een nee nar E 7 Items Xx y w tem nN J x Map 2 Bs j x Map 1 a x Map 0 Ip cal Composition Item properties Atlas generation 7 Item properties x ES Map 2 J p I Y Main properties E E Cache v Update preview 97 Scale 20598418 E a A al Map rotation 320 00 22 A a X Draw map canvas items X a e EE 2s Lock layers for map item al E E Ke w Extents Q X min 6347688 494 cm cm _ F Donnelly Baruch CUNY 2015 76 CC BY NC ND 4 0 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING 4 5 6 10 11 Add a legend Hit the e add new vector legend button and click on the lower right hand corner of the map With the legend selected go to the Item Properties tab and the Main properties menu
24. addresses you can look up or assign coordinates to them by using a geocoding service such as the Geocoding Services at the Texas A amp M GIS lab at http geoservices tamu edu or one of the geocoding plugins within QGIS Tabular Data Text Files Delimited text files along with XLS spreadsheets and DBFs are supported by QGIS as stand alone tabular data files You can add them to QGIS and join them to spatial data Unlike the other formats QGIS also allows you to plot coordinate data stored in text files to create spatial data In both cases you would use the Add delimited text menu and specify whether the data has coordinates to plot them or not because you re going to use the table for a join operation instead A text file is a plain document format that is often used for storing and sharing data Since it is relatively simple and contains no formatting it is cross platform and historically stable The attributes of each record are separated by a delimiter to indicate different fields This allows spreadsheet and database programs to parse the text file into columns when you open or import it into that software Common delimiters include commas tabs and pipes Files can be saved with the extension txt or csv CSV comma separated values files are text files that use commas as delimiters While they are stable cross platform easy to create and thus very common the disadvantage of text files is that the fields are not associated
25. an additional menu to the bar 2 Toolbar replicates many of the features and functions in the Menu Bar providing access to common features in a single click The location of the toolbars is not fixed if you hover over the edge of the toolbar and hold down the left mouse button you can drag and dock the toolbar wherever you like this means that the location of tools on your screen may not match those of other screens or this tutorial 3 Browser the browser allows you to see your file system and all of your GIS files and databases and lets you drag files from your file system into your project By default the Browser initially occupies this space in the interface but there are a number of other features you can enable that can share or occupy this area you can also switch the location of the browser with the map legend 4 Map Legend a list of the map layers that are part of your current project You can check or uncheck layers to turn them on and off drag them to change the drawing order select one in order to perform specific tasks on that layer and right click on a layer to access menus and tools for working with that specific layer Like the browser the legend can be moved or configured so that they are stacked or you can enable tabbed viewing to see just one at a time The Map Legend is sometimes referred to as the Table of Contents in other GIS software 5 Map Canvas geographic display that shows all of your active layers Also
26. around each other in districts Movie theaters and large shopping malls on the other hand tend not to cluster together they are spaced apart to serve different populations The location of non retail or non service industries is also distinct Manufacturing industries often depend on the availability of raw materials and inputs and the distance for finished products to reach transportation and markets while hi tech industries tend to locate near pools of highly educated labor Agricultural uses often appear where other land uses are not present and where land is inexpensive The types of crops or livestock they produce will vary based on environmental factors like climate or soil We worked with coffee shops in our exercise as they are an interesting example of a low order good they are small businesses that sell basic low cost products They have a relatively small footprint for attracting customers and can be located almost anywhere in the hopes of grabbing foot traffic coffee drinkers who want to grab something to go But in addition to this large general demographic they also appeal to particular groups who are seeking community space a certain atmosphere and better than average coffee These quality and place centric aspects of the business means they can t be entirely co opted by other food services that simply sell coffee like fast food retailers or donut shops large retailers or the Internet The bottom line if you are going to cond
27. but keep the susway stations turned off Save your project O subway_stations facilities greenspace Browser Layers E Donnelly Baruch CUNY 2015 31 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS 3 2 2 Commentary Geographic Units For this exercise we re working with census tracts which are statistical areas created by the US Census Bureau for representing census data for small areas Census tracts are designed to have an ideal population size of 4 000 resi dents with a typical range of between 1 200 and 8 000 people This means tracts will be roughly similar in population size so that equivalent comparisons can be made between them Since they re designed based on population their geographic size varies tremendously between urban and rural areas Tracts are built by combining smaller census statistical areas block groups and blocks and their boundaries typically correspond with major topographical features roads rivers or legal boundaries state county and municipal In dense urban areas census tracts are often used for representing population distributions within districts or neighborhoods Here is a summary of some of the most common geographic areas for thematic mapping in the US most countries will have some corollaries Counties Legal subdivisions of states counties are commonly used for mapping national or regional distributions given the large amount of data that s avail
28. button and click on any area in the interface you ll e Are there hotkeys Most menu items and tools can also be accessed by using hotkeys or keyboard shortcuts for example CTRL S will save the current project For a full list of hotkeys view the QGIS manual Many of the common Windows shortcuts like CTRL C for copy and CTRL V for paste will work in QGIS e Where is the QGIS manual These are available on the QGIS website at http www qgis org en docs 2 2 Adding Vector Data In this section you ll learn how to add vector GIS files shapefiles to QGIS and to symbolize them Shapefiles are a common GIS data format that you ll routinely encounter in your future work 2 2 1 Steps 1 Examine your data Minimize QGIS for a moment and take a look at the data files under the data folder for part 2 in your operating system s file browser or window These are shapefiles that we will add to QGIS and work with for this project There are five shapefiles each shapefile is composed of multiple files that have the same names but different extensions parte File Manager a a File Edit View Go Help ti E Desktop i gt y Trash File System C is Network 1 0 GB Filesystem amp IF 1 Documents a Download 143 Music a Pictures 18 Videos media 72CE F948 gis practicum part2 b_boundary dbf b_boundary prj re ee ae Shapefile b_boundary shp b_boundary shx boroughs db boro
29. can always save their GIS projects in a GIS project file The scale and extent of the data view symbolization and classification assigned to layers map layouts and links to GIS files used in the project are stored in the file It s important to understand that the GIS files themselves are NOT stored inside the project file the GIS data and the GIS project file exist independently When adding data to a GIS you are establishing a link from the GIS project to the GIS data the GIS data is not stored within the project Furthermore changing the colors of the features or classifying them in a certain way has no effect on the actual GIS data files themselves When you change symbols you are only changing how the GIS program views the data you re not changing the data itself This is an important concept to grasp Essentially the GIS software acts as a window for viewing and working with GIS data which is stored outside the window The GIS project file essentially stores the window dressing of scale and symbolization You never actually change the GIS data unless you go into an edit mode or conduct an operation that creates a new GIS file This relationship is of crucial importance when it comes time to move or share files if you move your project file or your data the links between them will become broken and you ll need to re establish the location between the project and the data in order to repair your project file 1 3 Open Source In thi
30. clear steps and plenty of screenshots Sherman and Mitchell s The Geospatial Desktop is great for delving deeper into QGIS and for providing a crash course in GRASS PostGIS and the GDAL OGR command line tools Stuck and need help Take a look at Geographic Infor mation Systems StackExchange an extensive question and answer forum at http gis stackexchange com In addition to QGIS and GRASS there are a number of other open source GIS products bouncing around that are worth a look gvSIG http www gvsig com en products gvsig desktop an open source desktop GIS package created by local government agencies in Spain is a notable alternative If you think you re going to become deeply involved in GIS you may want to consider trying the major pro prietary packages such as ESRI s ArcGIS or Pitney Bowes MapInfo If you re a current Baruch College student faculty or staff member you can sign up to take free self paced online courses in ArcGIS as part of the ESRI Virtual Campus program Visit the ESRI VC page under the Tutorials and Courses tab on Baruch GIS Guide at http guides newman baruch cuny edu gis esrive for information on how to sign up ArcGIS is available in several computer labs on campus CUNY affiliates outside of Baruch should contact the site license administrator of ArcGIS on your campus to see who administers the courses to gain access Many college and universities that have a site license for ArcGIS will probably also ha
31. color of roads on a map is highly standardized to show the type of road and volume thick blue roads are interstate highways thick green roads are toll highways thinner red roads are US highways and thinner black roads are state or local roads all ordinal symbols 4 7 Considerations and Next Steps Now that we have mapped this data what does it mean How would you interpret this map Are there any spatial patterns to the data clustering or does it appear more or less random Maps have the ability to answer questions but also raise new ones In order to understand what s going on we have to become familiar with the underlying dataset What influences voter participation and registration and how might that explain the distribution across different states For more practice some things to try e In addition to shaded areas we can also create graduated circle maps Convert the states Lcc polygon layer to a point layer using Vector gt Geometry Tools gt Polygon Centroids and in the Style tab under Layer properties symbolize the point layer based on the the percentage of the citizen population that s registered to vote PerRegCitz Click on each of the circle symbols one by one and modify their size so that larger values are F Donnelly Baruch CUNY 2015 85 CC BY NC ND 4 0 4 7 CONSIDERATIONS AND NEXT STEPS CHAPTER 4 THEMATIC MAPPING depicted with a larger circle Hop into your map layout and create a bi variate two variable
32. commas tabs or pipes can be created in just about any program and text files with coordinates can be converted into a spatial layer Add text ot csv files to QGIS using the Add delimited text layer menu See the next section for details e dBase files dbf An older data table format that s still widely used in GIS but that s been deprecated in versions of MS Excel from 2007 forward Can still be created with Libre OpenOffice Calc or various database programs See the appendix for details F Donnelly Baruch CUNY 2015 AO CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS Database tables QGIS is able to connect to a number of databases like PostGIS Spatialite and Oracle and can access both spatial and tabular data via database connections Tabular Data Spreadsheet Files Support for spreadsheet files was added to QGIS with the 2 x releases prior to that time only delimited text and dbase formats were supported for stand alone tabular data files The older Microsoft Excel spreadsheet format used from 97 2003 xls files is widely supported and is a safe bet for working with data tables Support for either the newer Excel format xlsx or the open document format ods is rather incomplete and will vary between operating systems and installations MS Excel xls files are still widely used and can be created and modified in any version of MS Office or Libre OpenOffice Calc In these prog
33. confidence interval is 90 Close the file when finished B C D E F 2 Table 4a Reported Voting and Registration of the Citizen Yoting Age Population for States November 2012 3 in thousands Registered Percent Total registered Margin of registered Total Error Total Population Total Citizen Population UNITED STATES ALABAMA ALASKA ARIZONA ARKANSAS B C D E ANSIFIPS ISTATE TotPop TotCitz TotReg PerRegPop 00 Ee e oa n o 2 01 ALABAMA 3594 3479 2556 71 1 3 02 ALASKA 516 495 361 69 9 4 04 ARIZONA 4863 4314 2812 57 8 5 05 ARKANSAS 2198 2109 1376 62 6 6 06 CALIFORNIA 28357 23419 15356 54 2 7 08 COLORADO 3817 3544 2635 69 0 8 9 CONNECTICUT 2726 2499 1760 64 6 a 1n NCLAVAIADC 602 6AA ATN 67 Q M 4 gt Table 4a Vote 3 IKI gt F Donnelly Baruch CUNY 2015 69 CC BY NC ND 4 0 4 3 MORE GEOPROCESSING AND JOINING CHAPTER 4 THEMATIC MAPPING 4 Add the Excel sheet to your project Maximize QGIS Hit the Vo Add vector data button Browse to the part 4 folder If necessary change the file type dropdown to show all types of files Select Tableoga xls Hit Open When prompted to choose a sheet select the Vote sheet Hit OK This will add the Vote table to the ML If you select it in the ML right click and open the attribute table you can verify that the data has been imported properly Notice the column ANSIFIPS has the two digit state codes If you close this table and view t
34. fill i e make them hollow with no color Double click on the B_BOUNDARY layer in the ML to open the Layer Properties menu for that layer Click on the Style tab Select the Simple fill box This modifies the options you ll see on the right Change the Fill style dropdown from Solid to No Brush In the Border Width box change the value from 26 to 75 Hit OK b_boundary Style Single Symbol v Se Symbol layer type Simple fill Colors Fill TS sorcer a Fill style No Brush Border style Solid Line oon ie Border width 0 750000 Offset X Y 0 000000 0 000000 Data defined properties 15 Millimeter v Millimeter v 10 Verify symbolization After completing these steps your QGIS window should resemble the image below CC BY NC ND 4 0 2 2 ADDING VECTOR DATA CHAPTER 2 EXPLORING THE INTERFACE Z QGIS 2 6 0 Brighton sA Project Edit View Layer Settings Plugins Vector Raster Database Help 5 H E 3 y Ro NW oe pe i y 3 L Su a Layers Y aap Browser Layers 2 2 2 Commentary Shapefiles A shapefile is a very common file format used for storing vector GIS data It was created by ESRI the company that produces ArcGIS the predominant software in the proprietary GIS market Shapefiles are an open GIS format that can be used in just about any GIS software package including QGIS A shapefile can consist of poi
35. for that estimate You would interpret the estimates thusly For Census Tract 16 in Bronx County were 90 confident that s the confidence interval for the ACS that median household income was 30 817 between 2009 2013 plus or minus 4 533 A B E D E F G id geography totpop fem18_49 per_fem medinc moe_medinc 36005000100 Census Tract 1 Bronx County New York city New York 11091 787 7 1 36005000200 Census Tract 2 Bronx County New York city New York 4334 1042 24 0 69514 16052 36005000400 Census Tract 4 Bronx County New York city New York 5503 1404 25 5 73036 11414 36005001600 Census Tract 16 Bronx County New York city New York 5643 1351 23 9 30817 4533 36005001900 Census Tract 19 Bronx County New York city New York 1917 476 24 8 33862 5001 36005002000 Census Tract 20 Bronx County New York city New York 8731 2193 25 1 19150 3411 36005002300 Census Tract 23 Bronx County New York city New York 4933 1231 25 0 13902 2195 3 Examine the attribute table of the tracts Close the Excel file exit your spreadsheet software and maximize QGIS Select the Tract layer in the ML right click and open the attribute table In the table note the column labeled GEOID It contains the same ANSI FIPS code the state county tract number that was stored in the id column in the data table Since these columns are the same we can use them to join the two files Close the table g Attribute table tracts_nyc_land Features total
36. it to the bottom of the ML Check the boxes beside all of the other layers GREENSPACE FACILITIES SUBWAYS BOROUGHS to turn them off for now greenspace facilities boroughs b_boundary tl_2012_ 36_tract_nysp Browser Layers 3 Activate the fTools plugin If you haven t done so already go to Plugins gt Manage and Install Plugins and make sure the fTools plugin is checked This will make the Vector menu appear on the menu bar 4 Select tracts within the b_boundary layer Go to Vector gt Research Tools gt Select by Location Select features in the tracts layer TL_2012 36_TRACTS_NYSP that intersect features in the borough boundary layer B_BOUNDARY Keep the top box that says Include input features that intersect the selection features checked Keep the other options unchecked Click OK You ll see that all tracts within the NYC boroughs have been selected as well as some that are outside and touching the selection is not perfect as there are some imperfections with the polygons Close the Select by Location menu when finished wa Select by location E 2S Select features in that intersect features in b_boundary v X Include input features that intersect the selection features Include input features that touch the selection features Include input features that overlap cross the selection features Include input features completely within the selection features Only selected features creating new selection z
37. map that shows the percentage of the population that s registered as circles and percentage of citizens who voted as shaded areas You ll have to turn the labels off as the map will look too busy e Since this is sample based data most of the values have a margin of error MOE associated with it in an adjacent column For example in Alabama in 2012 were 90 confident the confidence interval for the entire dataset that 61 9 of US Citizens voted in the PerVotCitz column plus or minus 2 4 in the PVC_MOE column How could you communicate this information about the margin of error in your map e At the beginning of this chapter we worked with a layer for countries Start a new project and using what you ve learned take the data file UN_INTERNET xLs stored in the part 4 folder and join it to the countries layer to make a thematic map hint use the admo_a3 column in the shapefile as the unqiue ID The data represents the percentage of a country s population that uses the Internet and was download from UN Data at Use one of the projected coordinate systems we created not the original WGS 84 layer There s an additional shapefile from Natural Earth that will give you a bounding box NE_50M_wGs84_BOUNDING_Box that you can underlay on your map make sure you re project it to match your countries layer E Donnelly Baruch CUNY 2015 86 CC BY NC ND 4 0 Chapter 5 Going Further This tutorial has provided you with a basic introduction
38. nationalmap gov viewer This federal agency provides imagery digital topographic maps DRGs elevation data and some boundary files Libre Map Project http libremap org a non profit site that provides all of the 24k scale USGS topo graphic maps DRGs for the US State of New York e CUGIR http cugir mannlib cornell edu Cornell University s Geospatial Information Repository They also compile data at the state county and local levels for NY State and they coordinate their activities with NYS GIS e NYS GIS Digital Orthoimagery Direct http gis ny gov gateway mg nysdop_download cfmi The NYS GIS page for imagery orthophotos tiles can be searched by county and year Imagery for the five boroughs for the most current series is only available by direct special request Imagery from the older series is available for all areas New York City e NYC OpenData https data cityofnewyork us this site is a repository of geospatial and attribute data from several city agencies e BYTES of the BIG APPLE http ww nyc gov html dcp html bytes applbyte shtml The NYC De partment of City Planning s page has administrative and political boundaries streets transportation networks shorelines and tax parcels Baruch Geoportal This is Baruch s GIS data repository at https www baruch cuny edu confluence display geoportal it includes a mix of public and Baruch only datasets Some can be downloaded directly from t
39. our temporary project and it looks the same as the plotted points this is a visual trick that QGIS is pulling on us It s re drawn the layer on the fly to match our original layer but in reality is has transformed the file Re open our Part 3 project by going up to Project gt Open Recent and select Part 3 When asked to save the current project say no and select Discard Back in Part 3 flip from the Layers to the Browser menu navigate down to the part3 folder and drag the corFEE_sHops layer into the view Flip the Browser menu back to Layers the coffee shops should be drawn on top and they match our underlying layers Layers x aeVaaga X 0 coffee shops O subway_stations X 7 facilities X greenspace E X lt tracts_nyc_data 0 8 8 22 22 27 27 34 34 67 _ boroughs KKXXXX 7 View the attribute table Select the corFEE_sHops layer in the ML right click and open the attribute table to take a look at what s there You should see all of the data that s affiliated with the coffee shops Close the table when you re finished Save your project 3 4 2 Commentary Coordinate Data Sources While government agencies often create and provide geographic data for boundaries and physical features private features like businesses are usually not captured These datasets must often be purchased or created from address or coordinate data ReferenceUSA is not a freely available resource but it is commonly held b
40. p File Edit Format View Help CODE STATE EMP_62 ID_TOTAL EMP_TOTAL OL AL 243502 ENUO100010010 1813155 AK 41671 ENU0200010010 316691 TAZ 303758 ENU0400010010 2356789 aR 182602 ENU0500010010 1134071 i El hc_emp_bls_2010 covt Notepad File Edit Format View Help 260193 ENUO800010010 2176986 ee 266748 ENUO0900010010 1595713 String string Integer string Integer 61592 ENULO00010010 399078 06 CA 1636175 ENU060001L0010 14414461 DC 64731 ENU1100010010 693274 3 5 Running Statistics and Querying Attributes In this section you ll learn to calculate basic statistics for attributes and use some of the advanced query features Now that all of the data is in place we can begin to remove tracts that don t meet our site selection criteria We want to target areas that don t have a large number of existing stores that have a high percentage of women aged 18 to 49 and that are not high income 3 5 1 Steps 1 Run some basic statistics On the menu bar select Vector gt Analysis Tools gt Basic Statistics Choose TRACTS_NYC_DATA as the input vector layer Change the target field to per_fem Hit OK You ll see that the mean percentage sum F Donnelly Baruch CUNY 2015 A6 CC BY NC ND 4 0 3 5 RUNNING STATISTICS AND QUERYING ATTRIBUTES CHAPTER 3 GEOGRAPHIC ANALYSIS the values for all tracts and divide by total number of tracts is approxi
41. projections a common mistake is to use the Define current projection tool under Vector gt Data Management Tools You should NEVER use this tool to transform projections its purpose is to define a projection for layers that are missing CRS data Always select the layer in the ML choose Save As and change the CRS for the new layer See the commentary for details 4 1 2 Commentary Understanding Coordinate Reference Systems All GIS layers are created using a specific coordinate reference system CRS The reason that we can take data from different sources and overlay them in GIS is because they share the same system likewise we can plot coordinate data and create layers because there s a coordinate system under the hood of our map window In order for everything to work your layers must share the same system and the map window must be defined to use that system GIS software can be used to transform layers from one system to another Each CRS is composed of at least three or four parts E Donnelly Baruch CUNY 2015 60 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING Spheroid or Ellipsoid We typically imagine the earth as a perfectly round sphere but in reality the earth is rather lumpy and uneven with protrusions in some areas and indentations in others The shape of the earth is approximated using spheroids round three dimensional models of the earth and ellipsoids which represent the earth as being
42. relative path saves the directory and file information for the folder the project file is in i e path would be boroughs shp and all folders below it i e path would be data boroughs shp Since anything above the project s directory is omitted relative paths are a good choice if you know that you ll be sharing your project data or moving it around Relative paths are a bad choice if your data is not going to be stored underneath your project folders i e it s stored above the project directory in a parallel directory or another drive or server all together Think carefully about where to save project files in relation to your data and once you ve created your project file keep project files and data in a consistent place Also remember that you must keep all of the individual components of a shapefile together shp shx dbf prj etc otherwise the shapefile will not function If you want to share your project file with someone you will also have to send them your data the project file cannot exist independently from the data You can share views or maps you ve created in a static format image file or PDF that is separate from your project and data files we ll explore that later in this tutorial F Donnelly Baruch CUNY 2015 25 CC BY NC ND 4 0 2 6 SAVING YOUR PROJECT CHAPTER 2 EXPLORING THE INTERFACE The QGIS project file qgs is actually just an XML file If you open the project file in a text editor you ll be able
43. save the changes and the columns become permanent Close the attribute table l Add column P X Name label_x Comment Type Decimal number real X double Width 10 2 Precision 4 2 4 Update label menu settings Before we can start moving labels we have to tell QGIS to store the positions for our labels in these new fields With the layer selected in the ML hit the labels button and on the labels tab go to the Placement menu Scroll down to the bottom of Placement to the Data defined menu In the dropdown for X Coordinate select Field type and choose the label_x field In the dropdown for Y coordinate select the label_y field For Rotation select the rotation field As you make the selections the drop down icons will turn from white to yellow Hit OK to save the settings ape Text Placement ab e Formatting abe Buffer Coordinate X Gy E Y Background Alignment horizontal y vertical 3 GEO_ID string Sor STATE string gt Placement Rotation ae X Preserve data rotation v i NAME string 4 Rendering Data defined override field v Priority i l LSAD string Activate D i CENSUSAREA double ow escription P label_x double ttribute field Ett labely double Load Style SS Field type string int double py double Vote_USPS string Edit Vote_STATE string Vote_TotPop double E Donnelly Baruch CUNY 2015 82 CC BY NC ND 4 0 4
44. see their placement in the edit mode When you re finished you can open the attribute table for the layer scroll to the right and you ll see that coordinates are stored in the x_label and y_label fields for the labels you moved Close the table 7 Adjust rotation for AK and HI labels Even though they may look fine in our map view our labels for Alaska and Hawaii are going to look askew when we re open our Map Composer This is because we rotated the maps of AK and HI so that they appeared normal in orientation relative to the rest of the country So we also have to alter the rotation for the labels to match Enter an edit mode Select the srares_tcc layer in the ML and hit the change label button Zoom up to Alaska and click on the AK label At the bottom of the Labels properties box type 330 in rotation and hit OK 330 is the number of degrees we rotated Alaska in the map composer you could go back into the composer to find this info Repeat the same step for Hawaii but specify a rotation of 320 Exit the edit mode and save the changes Fl Save your project F Donnelly Baruch CUNY 2015 83 CC BY NC ND 4 0 4 6 ADDING LABELS CHAPTER 4 THEMATIC MAPPING 8 Update your map composer Hit the Y Composer manager button select First map and hit Show You should see all your map labels don t worry if they appear overlapped they should turn out fine in the export If you don t see the labels hit the refresh butto
45. several decades old and should be used with that fact in mind The DRG was stored in a special tif format called a GeoTIFF a lossless image file that has georeferencing information coordinates and map projection embedded in it There are a number of great plugins for working with rasters like the gdal plugin for performing raster analysis and the georeferrencing plugin which allows you to convert non GIS image files i e a scanned paper map to a raster GIS file by assigning coordinates to it Given the time constraints of this tutorial we re not going to cover rasters beyond this point It was introduced here to give you a more complete picture of GIS capabilities and data formats If you re interested in learning more about rasters an addendum to this workbook called Working with Raster Data in QGIS was created for this purpose It focuses on working with digital elevation models and covers downloading tiling and warping re projecting DEMs and DRGs to create hill shades and contour lines The tutorial and data can be downloaded from http www baruch cuny edu geoportal practicum raster 2 6 Saving Your Project You ll learn how to save your project 2 6 1 Steps 1 Verify paths of files are relative and not absolute Under Project gt Project Properties gt General Tab for the last option in the General Settings area labeled as Save Paths verify that the selected drop down item is relative P Z Project Properties
46. the DPF DBFs are stand alone tables and can t be saved as multiple sheets Once you finished doing the work in the spreadsheet file do a copy and paste special in another workbook pasting only values no formulas or formatting Then you can save that sheet as a new DBF file F Donnelly Baruch CUNY 2015 97 CC BY NC ND 4 0 Appendix C Some Common CRS Definitions C 1 Geographic Coordinate Systems WGS 84 EPSG 4326 World Geodetic System of 1984 commonly used by organizations that provide GIS data for the entire globe or many countries and used by many web based mapping engines proj longlat ellps WG584 datum WGS84 no_defs NAD 83 EPSG 4269 North American Datum of 1983 commonly used by most US and Canadian federal government agencies the US Census Bureau in particular that provide GIS data The definition can be written in two different ways the first option is more common proj longlat ellps GRS80 datum NAD83 no_defs proj longlat ellps GRS80 towgs84 0 0 0 0 0 0 0 no_defs NAD 27 EPSG 4267 North American Datum of 1927 commonly used prior to the adoption of NAD 83 The earliest GIS files up until the mid 1990s or so employed NAD 27 and coordinate data for North America was recorded in this format for much of the 20th century proj longlat ellps c1rk66 datum NAD27 no_defs Since WGS84 NAD83 and all geographic coordinate systems are unprojected they will all look like Equirectangular or Plate Caree proje
47. the Style tab Each class represents the color of pixels on the map and since this is a digitized version of a paper map the colors tell you something about the feature type i e water is light blue forested areas are green Switch to the Histogram tab and it will show you how frequently each pixel occurs If you hover over the graph you ll see a magnifying glass you can left click and draw a box around the left side of the histogram to see the relevant values o to 12 more clearly Close the menu when you ve finished exploring Y Layer Properties drg_central_park Style CFE NG General V Band rendering Render type Paletted X aut sii Band Band 1 Palette liza Pyramids Value Color Label 4 Histogram fj Metadata DONAVA WN EO WON AUAWNH OC 11 11 12 O 12 j K lada Restore Default Style Save As Default Load Style Save Style GI F Donnelly Baruch CUNY 2015 22 CC BY NC ND 4 0 2 5 ADDING RASTER DATA CHAPTER 2 EXPLORING THE INTERFACE 4 Extract raster features Unlike vector features rasters have no attributes as the layer exists as a grid of pixels and not as discrete entities You can extract raster features based on their pixel values assuming that the values have some meaning i e the pixel value represents elevation terrain temperature etc Select the Raster menu in the Menu Bar and select the Raster Calculator if
48. them can become broken and you ll need to re establish the location between the project and the data in order to repair your project file If you open a project in QGIS and your project file can t find the data because the data has been moved or renamed the software will give you the opportunity to restore the link by asking you to browse through your file folders and select each file that corresponds to a layer you have in the ML of your project Once you restore the links you can save the project and it will save the new links Handle bad layers Paths to files can be stored as absolute links or as relative links An absolute link contains the complete path of a file such as F My_Stuff GIS_Practicum part2 data boroughs shp Use absolute paths when you re working in an established environment where you know that you won t need to move data and projects around or in situations where your project files won t be stored directly above or in the same folder as your data Absolute paths are a bad choice if you know you ll be moving data around they re a particularly bad choice if you re working on a usb drive in a MS Windows environment as the paths can change as you move from machine to machine i e F My_Stuff on one machine becomes E My_Stuff on another machine QGIS won t be able to locate the files stored on F My_Stuft because it doesn t exist that way on the 2nd machine Relative paths are the default choice in QGIS A
49. to think about page orientation it s appropriate to map the United States using a landscape page layout but if you were mapping an area that was taller rather than wider South America you d want to flip the page to portrait Individual map elements maps title arrow legend source text should be balanced on the page to achieve some harmony avoid lumping too many elements together or having large areas of white space The title and legend should concisely and accurately describe what the map is about and what you are mapping The amount of detail you provide and the terminology you use should vary with your audience You should always include the source of your data in the map The fonts north arrows and other elements should also be tailored to the map content a title in calligraphy font and an ornate compass rose may look good if you re recreating one of Christopher Columbus charts but it would look rather silly on our US voter participation map Maps are a form of communication designed to send a message Like a book or article that is poorly written maps that are poorly designed will fail because they do not effectively communicate their message to their audience Some reasons why maps can flop e Poor layout map elements map legend title text arranged in an uneven or sloppy way e Poor use of symbols circles too big or small not enough dots per person etc e Improper data classification too many or few classes that ob
50. to Project gt Save as Image Browse to your data folder for part 3 and save the image there as mar screen Change the Files of Type dropdown to PNG file Click Save 3 View your map Save your project and then close QGIS Navigate to your data folder for part 3 Look for the file maP_SCREEN PNG Double click it to open the file in your computer s default photo viewing program and youll see your map view This is a quick way to save and share your map content This is a simple static image file that is not connected to your project or data files You can easily email or text this file to anyone 3 7 2 Commentary File Management As we ve moved through this exercise we ve created many shapefiles along the way every time we made a selection or performed a geoprocessing function we ended up with a new file There are two things we should note here First this can get pretty confusing With each new file you create it s easy to lose track of what each one represents You can mitigate this by giving your files names that clearly indicate what they are Documenting your progress in a logbook whether it s on paper or in a simple text file can help you keep things straight You may also decide to delete files that were created during the middle of the process This is fine as long as you think you won t need to go back and re do a step either because the parameters of your project have changed or you ve spotted an F Donnelly Baruch CUNY
51. with a specific data type unlike a spreadsheet or DBF file where a field can be designated as a string integer real or other type When importing text files you need to be careful that columns are designated correctly during the import process strings inadvertently stored as numbers may have zeros dropped while numbers inadvertently stored as strings cannot be treated mathematically In the former case leading zeros dropped from ANSI FIPS ISO or ZIP Codes will be useless as identifiers and in the latter case numbers stored as text can t be classified numerically or used mathematically Sometimes QGIS will make correct assumptions when importing the data and E Donnelly Baruch CUNY 2015 A5 CC BY NC ND 4 0 3 5 RUNNING STATISTICS AND QUERYING ATTRIBUTES CHAPTER 3 GEOGRAPHIC ANALYSIS other times it won t To preserve values as numbers make sure you don t have any stray characters or footnotes stored in your numeric column In order to preserve values as text a common convention is to surround strings by double or single quotes and upon import they will be recognized as text Also values that contain a character that s used as a delimiter like New York NY can be preserved as a single string using quotes to prevent it from being incorrectly split into two values Text or CSV files that you download from the web may or may not use this convention Many database programs will either ask you if you want to surround strings with q
52. 1 20 000 000 Most GIS software have tools for generalizing boundaries if you need them to be more simplified Similarly the country file that we used in the previous section from Natural Earth was specifically designed for a scale of 1 50 000 000 Natural Earth offers most of its vector data in one of three scales the differences in detail are depicted below in this graphic from their website The file we used was Medium scale which was created at a level of generalization that s appropriate for making zoomed out maps of countries and regions or world maps on letter to tabloid sized paper 4 3 More Geoprocessing and Joining This section will demonstrate a few more geoprocessing techniques that you re likely to need You ll do another table join and will learn how to edit a layer in order to delete individual features E Donnelly Baruch CUNY 2015 68 CC BY NC ND 4 0 4 3 MORE GEOPROCESSING AND JOINING CHAPTER 4 THEMATIC MAPPING 4 3 1 Steps 1 Count features for your layer Select the startes Lcc layer in the ML right click and check the Show features count box It tells us there are 52 features That s 50 states plus two DC and Puerto Rico 2 Edit the layer Since we re not going to have any voting data for Puerto Rico in our data table we re going to modify our shapefile to delete that feature Select stares Lcc in the ML to activate it then hit the Edit button on the toolbar alternatively you can right click on th
53. 2015 16 CC BY NC ND 4 0 2 3 EXPLORING THE MAP VIEW CHAPTER 2 EXPLORING THE INTERFACE Adding Data and Drawing Order When you add map layers or data to a map view you are technically not adding data to the window i e copying the file and inserting it into the project Rather you are establishing a link between the GIS interface and the files which exist independently from the software When you use GIS software to change the symbolization of the layers colors outline labels etc you are not modifying the data file itself you are simply telling the software to display the layers in a certain way The software is essentially a window for viewing the data files The only way to change the data files themselves their geometry or attributes is within an editing mode which you must specifically launch For much of the 20th century maps were created by taking individual layers on translucent mylar sheets and laying them over top of a paper base map For example an outline of the United States with boundaries of each state could serve as a paper base map with individual mylar sheets layered on top that had rivers and cities The order of the sheets determined which features appeared on top covering up other features GIS functions the same way the order of the layers determines which appear on top If you move a polygon layer with a solid fill i e boroughs over top of a point layer i e of subway stations you will not see the stations as th
54. 28 AUTHORITY EPSG 9122 AUTHORITY EPSG 4326 This file tells us that the shapefile is projected in the World Geodetic System of 1984 WGS 84 and provides us with information about the various components of that CRS Close the file when you re finished Add the countries shapefile Maximize QGIS Tab to the browser browse to the part 4 folder and add the NE_50M_ADMIN_O_COUNTRIES shapefile select it in the browser and drag it into the project or select right click and choose Add to project Tab back to the Layers menu Hover over the map and at the bottom of the screen in the Coordinate window note how the coordinates change Given the size of these numbers we can tell that these are in degrees To the right of the coordinates hover over the text that says EPSG 4326 this code is a unique identifier for different CR systems A little window appears that tell us the current CRS is WGS 84 Save your project Browser Layers Coordinate 154 8 122 5 Scale 344 432 197 Render EPSG 4326 Oy A current CRS WGS 84 4 Transform the projection Let s transform the layer to something that s more suitable for a thematic map Instead of using WGS 84 which is a basic geographic coordinate system GCS we are going to use a projected coordinate system PCS Select the countries layer in the ML Right click and hit Save As Hit the CRS globe button beside the CRS entry In the CRS Selector window type Mo
55. 95 PROJECTION Lambert_Conformal_Conic_2SP PARAMETER False_Easting 0O PARAMETER False_Northing 0 PARAMETER Central_Meridian 96 PARAMETER Standard_Parallel_1i 20 PARAMETER Standard_Parallel_2 60 PARAMETER Latitude_Of_Origin 40 UNITL Meter 1 AUTHORITY EPSG 102009 From this definition we can see that North America Lambert Conformal Conic projection uses GRS 1980 as a spheroid NAD 83 as the datum and meters as the unit of measurement for the coordinate system As a conformal projection it preserves angular relationships Geographic reference systems have also been classified with codes which makes them easier to identify and retrieve QGIS uses a CRS library called the European Petroleum Services Group EPSG This library originally contained most of the primary GCS systems such as WGS 84 and NAD 83 and local PCS systems like State Plane For example EPSG 4269 is the code for NAD 83 and EPSG 4326 is the code for WGS 84 The advantage of the codes is clearer when you re working with longer names NAD 83 NY State Plane Long Island feet is abbreviated to EPSG 2263 The EPSG library originally lacked most of the PCS systems for global and continental map projections like Mollweide Robinson and North America Lambert Conformal Conic but with the 2 x releases the developers have augmented the library to include these projections Formerly one had to search Spatial Reference to find the pro
56. Ceras Burau Vtg and Regitrticn in Pe Detiene O 55 9 61 9 Noemi 202 Oemlec Boks Ge 619 676 Map casing by Fark Donnal Banah CUNY Dec 203 MA 676 75 9 13 Print to PDE PDFs are good for stand alone maps Before you export make sure you don t have any map elements selected and return to the Composition tab for the map Hit the export to PDF button and save your map as a PDF file voreRs_2012 PDF in your part 4 data folder The program may hang for several seconds while the map is being exported After a few moments you can click on the composer to reactivate it or minimize and maximize QGIS to get back to the composer 14 Export as PNG You can also save your map as an image file like a JPG or PNG Normally we would want to design the map to be the size of the desired image and we d want to adjust the DPI quality just above the Print as Raster checkbox in the Composition tab to reduce it s size Hit the export as image button Browse F Donnelly Baruch CUNY 2015 78 CC BY NC ND 4 0 4 5 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING to your data folder for part 4 and save the map there as voTERS_2012 PNG Make sure that you specify PNG as the file type After you hit save QGIS may hang for a moment while it exports the file just wait for a few seconds and the export will be finished 15 Take a look at your maps Minimize QGIS and use your file browser to go to your part 4 data folder Double click on the PDF file to o
57. F Donnelly Baruch CUNY 2015 81 CC BY NC ND 4 0 4 6 ADDING LABELS CHAPTER 4 THEMATIC MAPPING 2 Inspect the labels At first glance the label placement looks pretty good There are a few small issues the labels for Florida and Louisiana look a little off center And if you re zoomed out so the contiguous 48 states fill the screen the label for Washington DC is omitted as it overlaps with labels of neighboring states With a little extra work we can fix that 3 Add new columns to the attribute table The labels are automatically placed in the center of the state In order to define and store a specific position for them we have to add some new columns to the attribute table And to do that we ll have to enter an edit mode so we can actually modify our file Open the attribute table for stares Lcc Hit the edit button at the top of the table Hit the New column button In the Add Column window name the new field label_x Assign it a Decimal number type Give it a width number of characters of 10 and a precision number of decimal places of 4 Hit OK and the new column gets tacked on at the end of the table The label_x column will hold the X longitude coordinates for our label But we need a second column to hold our Y coordinates latitude Repeat the previous step to add a second column called label_y Finally add a third column called rotation and give it the same attributes Once you ve added it hit the edit button to
58. General P X R Tor w General settings de aE Project file z pam gis_prac_data part2 part2 qgs gt Project title ER identify layers Selection color wW Background color Default styles Save paths relative 2 p 2 Save your project Hit the save project button Navigate to the data folder for part 2 and save your project there as PART2 QGS The project file saves the symbolization labeling and current zoom for your data and links to your data files shapefiles the shapefiles themselves are NOT stored inside your project file and exist independently In order to use your project in the future the project file and the shapefiles you used must be kept together F Donnelly Baruch CUNY 2015 24 CC BY NC ND 4 0 2 6 SAVING YOUR PROJECT CHAPTER 2 EXPLORING THE INTERFACE 2 6 2 Commentary Project Files When you add data to a project file you are not saving the data shapefiles inside the project you are saving links to those files Elements like symbolization data classification the extent of your last zoom and any finished maps you create are stored in the project file When you click on the project file to open it the software looks at the paths to your data re establishes the links and then applies the settings symbols zoom etc that you have saved in your project file This relationship is of crucial importance when it comes time to move or share files if you move your project file or your data the links between
59. HIC ANALYSIS e USGS Topo Base Map http basemap nationalmap gov ArcGIS services USGSTopo MapServer WMSServer e USGS Imagery Topo Base Map http basemap nationalmap gov ArcGIS services USGSImageryTopo MapServer WMSServer e OpenStreetMap Global http ows terrestris de osm service VERSION 1 1 1 amp Please note these URLS will not work in a web browser You must use them within GIS software to connect to the service An alternative to adding WMS layers one by one would be to use a plugin that already includes connections to many services Under Plugins Manage and Install Plugins search for the OpenLayers Plugin If you install it a new Web menu will be added to QGIS and you can choose from several map services including OSM Google Bing and MapQuest 3 7 Screen captures In this brief section you ll learn how to create a screen shot of your map that you can easily share with others You ll learn how to make a presentation quality map in the next chapter 3 7 1 Steps 1 Zoom to layer Uncheck the WMS layer to turn it off With the sELEcTED_aAREAs layer selected in the ML hit the zoom to layer button Use the hand tool to center the map view If you want something fancy you could activate some plugins under Plugins gt Manage and Install Plugins and add a north arrow scale bar and copyright info to the screen and the text annotation button to add a title 2 Save the map view screen On the menu bar go
60. Introduction to GIS Using Open Source Software Frank Donnelly Geospatial Data Librarian Baruch College CUNY July 2015 Creative Commons Attribution NonCommercial No Derivatives 4 0 International License CC BY NC ND 4 0 Contents Introduction 1 1 An Overview of GIS 4 it Basi Gls CONECDIS e ramaw a Bee ee ee a AAA 4 1 2 GIS Software ooa a eee 8 La OM COUICCE Si aa dead iw eee eet eter de eee eae ee gat Sen eee ea eee eee eS 9 2 Exploring the Interface 11 21 The QGIS Interface i e 6nd cd ed deadwood dame ns dara AAA 11 Ar eee a ea a a AAA 11 Bao CO ple araa A a e 12 a a e 12 a oa sae a hak cena sae ade 13 13 16 16 17 17 17 232 COMMENTA e caera eR OME ora A 18 Options Menu geese ee bee GA EERE ERED SEES SRD AAA 18 24 Exploring Beatles lt ise narra FSH ASE BOS EES HEDGES AR 19 SAL DEDO sesos roer ear ee ee eras eee tea es 19 CAS COMMENTS o RO ook oe Se wee Gee ee a oe a Aa 21 Attribute Tables cazas ada ed hee he CS Oe AAA 21 orar aata sb eos aleta Tes 22 care aa ae aa ao ea apa e 22 252 COMNEN lt oe es oe da aa aa ee ee ee ee ee oe Se eS 24 oot bie eee ee le ee ae ae E be ee a eo E ee ee ee 24 VGe eee bee eES eas aa eo Ree aero eh ews 24 Pe oh oe ee a ee ee he ee eae a ae ee ee ae ee a eee 24 202 COMMeCNAly a3 4 a s amp h eae ee he ORGS RRO eS ee REE ESKER ESA DE MG OR 25 Project A II 25 3 Geographic Analysis 27 3 1 Creating New Project From Existi
61. L right click and choose Save As Browse to the part 3 data folder and Save the layers as TRACTS_NYC_DATA Leave the encoding and the CRS alone and make sure the Add saved file to map box is checked Hit OK P g Save vector layer as E xs Format ESRI Shapefile z Save as _prac_data part3 tracts_nyc_data shp Browse CRS Layer CRS y NAD83 New York Long Island ftUS Change Encoding System Sl a Save only selected features Skip attribute creation X Add saved file to map Symbology export No symbology v Scale 1 50000 b Extent current layer OK Cancel Help 7 Reorder the layers Select the TRACTS_NYC_LAND layer in the ML right click and remove it Also remove the data table SHEET1 Drag the new TRACTS_NYC_DATA layer to the bottom of the ML just above the BoroucHs layer If you open the attribute data for the new TRACTS_NYC_DATA you ll see the data from the table has been fused to the shapefile Save your project F Donnelly Baruch CUNY 2015 37 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS 8 Map the data Now that the data is joined to the boundaries we can map it Double click the TRacTs_Nyc_paTA layer in the ML and go to the Style tab Change the Legend type dropdown from Single symbol to Graduated Change the Column to per_fem percentage of the population that are females between the ages of 18 and 49 Change the mode from Equal Interval to
62. Lj J al 1 oot H i i a il l hor f r F z Ter 4 A E LL L 4 1 ut L 4 d L F d F F J ru gt a ho E do i a r F T F i i m pon E O T PE e AP a aa ia F Donnelly Baruch CUNY 2015 100 CC BY NC ND 4 0 Appendix D ID Codes e ISO Country Codes http www iso org iso country_codes htm e US ANSI FIPS Codes http www census gov geo reference ansi html INCITS 38 2009 ID Codes for US States formerly FIPS 5 2 Name ANSI FIPS USPS Code Name ANSI FIPS USPS Code Alabama 01 AL Montana 30 MT Alaska 02 AK Nebraska 31 NE Arizona 04 AZ Nevada 32 NV Arkansas 05 AR New Hampshire 33 NH California 06 CA New Jersey 34 N Colorado 08 CO New Mexico 35 NM Connecticut 09 CT New York 36 NY Delaware 10 DE North Carolina a7 NC District of Columbia 11 DC North Dakota 38 ND Florida 12 FL Ohio 39 OH Georgia 13 GA Oklahoma 40 OK Hawaii 15 HI Oregon 41 OR Idaho 16 ID Pennsylvania 42 PA Illinois 17 IL Rhode Island 44 RI Indiana 18 IN South Carolina 45 SC Iowa 19 IA South Dakota 46 SD Kansas 20 KS Tennessee 47 TN Kentucky 21 KY Texas 48 TX Louisiana 22 LA Utah 49 UT Maine 23 ME Vermont 50 VT Maryland 24 MD Virginia 51 VA Massachusetts 25 MA Washington 53 WA Michigan 26 MI West Virginia 54 WV Minnesota 27 MN Wisconsin 55 WI Mississippi 28 MS Wyoming 56 WY Missouri 29 MO 101 APPENDIX D ID CODES INCITS 38 2009 ID Codes for US Territories formerly FIPS 5 2 Name ANSI State Numeric Code USPS Code American
63. Samoa 60 AS Guam 66 GU Northern Mariana Islands 69 MP Puerto Rico 72 PR U S Minor Outlying Islands 74 UM U S Virgin Islands 78 VI SGC Codes for Canadian Provinces and Territories 2011 Name SGC Code Canada Post Code Alberta 48 AB British Columbia 59 BC Manitoba 46 MB New Brunswick 13 NB Newfoundland and Labrador 10 NL Northwest Territories 61 NT Nova Scotia 12 NS Nunavut 62 NU Ontario 35 ON Prince Edward Island 11 PE Quebec 24 QC Saskatchewan 47 SK Yukon 60 YT F Donnelly Baruch CUNY 2015 102 CC BY NC ND 4 0
64. _defs Visually the difference between State Plane on the left and UTM 18 North on the right is almost imperceptible when focused on the NYC area but both are clearly distinct from the basic GCS WGS 84 NAD 83 C 3 Continental Projected Coordinate Systems US National Atlas Equal Area EPSG 2163 More commonly known as the Lambert Azimuthal Equal Area projection this CRS preserves equal areas and true direction from the center point of the map It was the best CRS in the original EPSG library for thematic mapping on the North American continent but since QGIS has expanded the CRS library there are better options proj laea lat_0 45 lon_0 100 x_0 0 y_0 0 a 6370997 b 6370997 units m no_defs F Donnelly Baruch CUNY 2015 99 CC BY NC ND 4 0 C 4 GLOBAL PROJECTED COORDINATE SYSTEMS APPENDIX C SOME COMMON CRS DEFINITIONS North America Lambert Conformal Conic EPSG 102009 Perhaps the most common map projection for North America a conformal map preserves angles LCC can be modified for optimally displaying specific countries i e USA and Canada other continents i e South America Asia etc or other ellipsoids and datums WGS 84 proj 1cc tlat_1 20 lat_2 60 lat_0 40 lon_0 96 x_0 0 y_0 0 tellps GRS80 datum NAD83 units m no_defs North America Albers Equal Area Conic EPSG 102008 An alternative to LCC all areas in an AEAC map are proportional to the same areas on the Earth Can also be modified for sp
65. a How did they create the data For vector files are the layers generalized or not What scale are they appropriate for For vector files are the polygons saved as single or multipart layers For vector files what attributes are available in the attribute table Are there ID codes that I can readily use to join data Are there place names that I can readily use as labels For raster files what is the resolution of the data Is it appropriate for my intended use e What format is the file in Is it a format I can use or at least one that I can easily convert e Are there any copyright or use restrictions with the data Finally remember that GIS data is often just one piece of the puzzle It represents the geographic features but if you need attributes to go with these features demographic data weather data sales data etc you ll have to download this data from someplace else or create it yourself and process it to make it usable with your GIS data 5 2 Data Sources Meta e OpenGeoportal http opengeoportal org This is collaborative community of geospatial professionals primarily at universities who share data and metadata from their individual institutions through an open suite of software that the group develops The link brings you to the project You can access the repositories of individual institutions through their portals a few examples are Tufts http geodata tufts edu Harvard http calvert hul harv
66. able for them New York City is unique as it s the only US city composed of multiple counties and for historical reasons the five NYC counties are referred to as boroughs City agencies classify data using borough names Bronx Brooklyn Manhattan Queens Staten Island while federal agencies like the US Census Bureau use county names Bronx Kings New York Queens Richmond Dataset availability 2010 Census 1 and 5 year ACS population estimates PUMAs Public Use Microdata Areas Statistical areas created by the US Census Bureau to have approximately 100 000 residents they re created by aggregating census tracts In urban areas they can represent subdivisions of cities in suburban areas they represent subdivisions of counties and in rural areas they are often aggregates of several counties There are 55 PUMAs in NYC they are occasionally referred to as sub boroughs Dataset availability 1 and 5 year ACS ZCTAs ZIP Code Tabulation Areas Statistical areas created by the US Census Bureau to approximate areal USPS ZIP Codes The Census Bureau creates ZCTAs by aggregating small statistical areas called census blocks based on the location of addresses within the blocks While not always ideal for representing neighborhoods ZIP Codes are often used for this purpose since most people are familiar with them ZCTAs do not correspond with other census geographies Dataset availability 2010 Census and 5 year ACS F Donnelly Baruc
67. aces 9 ick Start Race and Ethnic Groups p race ancestry tribe os r Enter search term s and click GO View the Amrican FactFinder Data Release Schedule industry Codes b topic or table name state county or place optional NAICS industry for Download large volume data from the O topics race ancestry industries Census Bureau s FTP Site 4 w All the datasets from the US Census are available for download from the bureau s American Factfinder data portal at http factfinder2 census gov All of the data is free and in the public domain When you download the data you may have to process it to aggregate certain variables before you can use it The data that we are using in this exercise has been preprocessed to aggregate certain columns and delete unnecessary ones Census data from other countries may be more difficult to obtain as is may not be free or in the public domain may not be documented in English and may not be available in a digital format You can check the website of the statistical agency for an individual country to see what is available or you can visit the websites of international organizations like the United Nations or World Bank to obtain basic population data for all countries The US Cen sus Bureau also publishes the International Data Base which has a variety of demographic indicators for each country The decision of which census variables to examine in this study w
68. alled Robinson Robinson is a compromise projection that doesn t preserve any one property of the earth s surface it was designed for optimal visual appearance and is widely used in atlases and thematic maps In most GIS software libraries of GCS and PCS system definitions are stored or organized separately under their own menus or tabs Latitude and Longitude The most common coordinate system is latitude and longitude a grid system that covers the earth and uses a unit of measurement called a degree Lines of latitude called parallels run east west The origin of latitude is the equator which is zero degrees latitude The equator bisects the earth and along this line there are twelve hours of daylight and twelve hours of darkness each day throughout the year Lines of latitude run 90 degrees to the north pole and go degrees to the south pole One degree of latitude is equal to approximately sixty nine miles and since they are parallel lines they never converge F Donnelly Baruch CUNY 2015 61 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING Lines of longitude called meridians run north south Unlike the equator which is the defacto line of latitude based on natural phenomena the selection of an origin for longitude is arbitrary The Prime Meridian zero degrees longitude was designated as the origin parallel in the 19th century It runs through the center of the astronomical observatory in Greenwi
69. ame on Save your project F Donnelly Baruch CUNY 2015 75 CC BY NC ND 4 0 4 5 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING 50 100 150 200 250 an nana enn Ten id Bing cnn enana nd nen an AN cs y 100 50 o EENE anna EEEE EE EE E E A to Ga de 150 MN bas A hd 200 5 Add additional maps for Alaska and Hawaii Given the vast distances between the lower 48 states Alaska and Hawaii it doesn t make sense to include them in the same map window at the same scale look at most maps of the US and Alaska and Hawaii appear in separate boxes so that optimal scale can be achieved for all three areas we ll do the same with our map Hit the add map button and draw a smaller box in the lower left hand corner Use the move item button to shift the focus of the map to Alaska and with this button selected use the map wheel to change the zoom If you have trouble getting the zoom right there are two methods you can try With the new Alaska map box selected open the Item properties tab on the right Under Main properties watch how the scale changes as you zoom in and out with the mouse wheel In the scale box type in a number that s somewhere in between Alternatively you could minimize the composer and back out in the data virew zoom in to Alaska so it s centered in the view Then return to the composer and under Item Properties under Extents click the Set to map canvas extent button
70. amples of codes with leading zeros include Census ANSI FIPS codes and USPS ZIP Codes In order to join two tables together based on an identifier you need to be sure that each field is stored in the same data format if one is stored as text and the other is numeric the join will fail Furthermore you need to insure that each record is unique because one to many joins are not allowed if you have a data table that has multiple records for one country only one of those records will be joined to a shapefile and the others will be dropped Finally you should never use place names as identifiers or join fields because there are often many inconsistencies imagine the number of different ways for spelling or abbreviating country names like the United States or South Korea Adding or appending identifiers to tabular data that lack this information is a common data processing task that you ll likely have to perform 3 3 3 Tabular Data Files for QGIS Currently there are four different formats that you can use to get non spatial tables into QGIS for the purpose of joining the tables to spatial files e MS Excel 97 2003 spreadsheet files xls This is perhaps the simplest format for new users as these files can be Vo created in virtually any spreadsheet program Add them to QGIS using the Add vector data menu See the following subsection for details e Delimited text files csv or txt Plain text files with fields separated by delimiters
71. an profoundly affect the interpretation of a distribution or pattern and the ultimate message that your map sends Mapping populations of US states or Canadian provinces is fine if you are interested in seeing which ones have the most people But these maps tell you very little about how the population is distributed across these countries since there is considerable variation in the concentration of people in each state province Using a smaller unit of geography can give you a better idea of the distribution of the population For example compare the state level election map above with a county level map that depicts majority votes by political party 2012 Presidential Election County Vote ON gt nanos EA Republican gt gt MM Democrat No Data Oftentimes you ll be limited to using certain geographic units based on the availability of the data making it necessary to compromise ColorBrewer ColorBrewer is an online tool for choosing good color schemes for thematic maps QGIS has integrated many of the schemes from ColorBrewer by default and you can access additional ones by hitting the drop down Color Ramp drop down menu in the Style tab choosing the New Color Ramp option at the bottom and selecting ColorBrewer It s still worth visiting the site at http colorbrewer2 org for color selection advice The tool let s you choose the number of classes and class options like sequential for quantitativ
72. ard edu 8080 opengeoportal Columbia http culspatial cul columbia edu e Geolode http geolode org This resource contains searchable records with links to hundreds of websites from around the world that provide freely available GIS data It was created by the Geospatial Librarian at Cornell University and is maintained by volunteers who work in GIS positions in universities Global e DIVA GIS data http www diva gis org gData Country level vector and raster data for every single country in the world Download individual files or geodatabases Assembled for the BioGeomancer Project at UC Berkeley and part of the DIVA GIS project For just global administrative boundaries you could also visit the GADM database page at http www gadm org e Natural Earth http www naturalearthdata com Generalized raster and vector data for countries avail able at three different scales e United Nations Environment Program http geodata grid unep ch Geodata Portal Click on Advanced Search select Geospatial Data Sets under the first drop down box and hit the red Search button This will take you to a list of global or continental GIS files that you can download e Center for International Earth Science Information Network http sedac ciesin columbia edu data Center for International Earth Science Information Network hosted by Columbia University it contains links to datasets for the world various countries and the US F Do
73. ary lines for reference purposes then you E Donnelly Baruch CUNY 2015 34 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS will want to use the files as is However if you want to map the distribution of phenomena by area you ll want to process the boundaries to remove water as that phenomena isn t likely distributed there i e there are no people living in the harbor You d also want to alter the boundaries if you re creating maps and want the user to be able to clearly understand the areas you re depicting The Clip tool accomplishes this by modifying one set of boundaries to match another the Difference tool could also accomplish this by subtracting areas representing bodies of water from the boundaries resulting in features that depict land This is merely one application and tool in the geoprocessing toolkit Geoprocessing is essentially a GIS operation to manipulate the spatial aspects of GIS data In the broad sense it includes layer overlay feature selection data conversion and topology processing In a more narrow sense that we re using here it refers specifically to topology processing modifying the actual geometry points lines and areas of features and files Via the ftools plugin Vector menu QGIS has the following Geoprocessing tools for vector layers running each tool creates a new layer it does not modify existing layers Q Convex Hull s P Buffer s Cw Intersect
74. as made by consulting psychographic data and market research reports This data is generated by marketing surveys to determine which groups of people are interested in products or activities relative to other groups based on age gender race occupation education level and geographic location The census data for this exercise was chosen based on statistics from the Mediamark Reporter a series of psychographic reports published in a database called MRI This data is not freely or publicly available you would have to access it through an organization that subscribes to the database Identifiers The ability to join data tables in a database or a data table to a shapefile is made possible by the use of identifiers which are codes used to uniquely identify features If features in two separate data tables share the same identifier those data tables can be matched or joined together based on that common identifier allowing you to create new data or to map data in a table There are several standard codes for identifying features In the United States ANSI FIPS Federal Information Processing Standards codes are a classification system for identifying all legal administrative and statistical areas in the country For example ANSI FIPS 36061000201 is the code Census Tract 2 01 in New York County Manhattan The first two digits 36 are the code for New York State the next three digits 061 are the unique code within New E Donnelly Ba
75. ast e Refresh redraws the screen useful if your layers didn t draw completely or properly 2 Notice change in coordinates Move the cursor around the map In the Status Bar below the Map View notice how the coordinates change coordinates for the map are provided based on the position of the cursor If you hover over the box that says EPSG 2263 a pop up window tells us the coordinate reference system CRS of the project based on our layers is NAD 83 New York Long Island ftUS This is the local state plane system that is appropriate for our area which is used by agencies in NYC that produce spatial data In the state plane system coordinates are measured in feet We ll cover coordinate reference systems later in the tutorial The scale box can also be used to change the zoom a higher number to zoom out and a lower number to zoom in F Donnelly Baruch CUNY 2015 17 CC BY NC ND 4 0 2 3 EXPLORING THE MAP VIEW CHAPTER 2 EXPLORING THE INTERFACE Coordinate 1041016 235149 Scale 1 264 597 y Render EPSG 2263 A 3 Measure some distances Use the zoom tools to center Manhattan in your map window Select the measuring distance tool in the toolbar You ll notice that crosshairs will appear Click on the northern tip of Manhattan This will open the Measure window Drag the crosshairs to the southern tip of Manhattan As you do this you ll see an orange line is drawn from the original point you clicked on and the measur
76. b services For example if you completed the exercises in Chapter 3 drill down to the Part 3 folder to see all of the files we used or created for this chapter 3 View the metadata for coffee_shops Select the corFEE_sHops layer in the folder tree The default tab on the right will show you basic metadata for the file including the type and number of features 601 point features the spatial extent of the layer in coordinates and the definition for the CRS Y QGIS Browser 25 Ao Refresh Ea Manage WMS Ve New Shapefile Set layer CRS 4 Li gis_prac_data a Param Metadata Preview Attributes 4 5 part2 2 b_boundary shp A z boroughs shp Storage type of this layer drg_central_park tif ESRI Shapefile e ie ER Description of this provider facilities shp greenspace shp te pe qa o m GDAL OGR library version 1 11 0 running against subway_stations shp 4 part3 Source for this layer t buffer_subway shp IC coffee_shops shp nyc_coffee txt E pa FE gis_prac_data part3 coffee_shops shp Geometry type of the features in this layer Point selected_areas shp sl t1 2012 36 tract_nys The number of features in this layer tracts_data_count shp 601 gt tracts_nyc shp Editing capabilities of this layer y tracts_nyc_data shp 4 Preview the coffee_shops Select the Preview tab to preview the geography of the layer Select the Attributes tab to preview the attribute
77. ch UK There are 180 degrees of longitude to the east and to the west of the prime meridian The meridian that is opposite the prime meridian on the far side of the globe 180 degrees longitude is the International Date Line approximately Unlike latitude longitude converges at the poles to a single point at zero degrees Since lines of longitude converge there isn t a uniform distance between them the distance decreases as you move away from the equator At the equator one degree of longitude is approximately 69 miles across while at the poles it is zero miles There are two conventions for recording coordinates in degrees minutes and seconds DMS or as decimal degrees DEC Take a look at the following coordinates for Philadelphia PA from the USGS GNIS gazetteer 39 deg 57 08 N 75 deg 9 50 W DMS 39 952335 75 163789 DEC The DMS notation is similar to the notation for telling time there are 60 minutes in one degree and 60 seconds in one minute DEC notation is preferable for computer processing if you re plotting coordinates in GIS they should be in DEC In DEC latitudes south of the equator and longitude west from the prime meridian to the international date line are recorded as negative numbers It is crucial that DEC coordinates indicate direction otherwise you ll be confusing your point with a different place 39 952335 75 163789 is Philadelphia PA USA 39 952335 75 163789 is a remote area in western
78. ch is a 100 count of the population mandated by law to reapportion seats in Congress The ACS is an annual sample survey of population characteristics Each year the census publishes annual ACS estimates for all geographic areas in the US that have at least 65 000 people Estimates are at a 90 confidence interval and are published with a margin or error Since the survey results for areas with smaller populations are often not statistically significant the bureau averages data over a 5 year period for smaller areas This includes all geographic areas with less than 65 000 people down to the census tract level Each year the bureau releases a new annual data set and updates the 5 year averaged series by adding the latest year of data and dropping the oldest one For our exercise we are using 5 year average data as that s the only ACS series that is published at the tract level Note the Census Bureau previously published a 3 year dataset for areas that had at least 20 000 people but due to budget cuts this dataset will no longer be released The American Community Survey was designed to provide data on a frequent basis and to replace the form on the decennial census that collected detailed socio economic characteristics of the population Beginning with the 2010 Census the decennial census only provides basic demographic indicators of the population such as age gender race and the total number of households and housing units The decennial census
79. ck and select New Connection In the Connection window type Open Streetmap for Name and for the URL enter http ows terrestris de osm service Instead of typing you can copy and paste from the wms_links txt file stored in the part3 folder Hit OK Browser X or Y Gi Z Create a new WMS connection E Project home 7 i f Connection details Favourites si Name Open Streetmap a ey URL http ows terrestris de osm service VERSION 1 1 1 amp E bi If the service requires basic authentication enter a user name and H optional password a J mssar a oracle User name 7 y ia Password 5 SpatiaLite a ows Referer Es DPI Mode all GE WFS E D WMS Ignore GetMap GetTile URI reported in capabilities Ignore GetFeatureInfo URI reported in capabilities Ignore axis orientation WMS 1 3 WMTS Invert axis orientation Smooth pixmap transform 8 Render WMS and style layers Hit the little plus symbol to expand the WMS layers then expand the Open StreetMap OSM layer and drag the OpenStreetMap WMS into your map view Depending on your Internet F Donnelly Baruch CUNY 2015 52 CC BY NC ND 4 0 3 6 DRAWING BUFFERS AND MAKING SELECTIONS CHAPTER 3 GEOGRAPHIC ANALYSIS connection it may take a few seconds to load Tab back from the Browser to the Layers menu Drag the OSM layer so that it is directly below sELECTED_AREAS Double click on sELECTED_AREAS in the ML and in the Style tab move the transpare
80. ctions regardless of scale Global view on the left zoomed into NYC on the right EA a ll El bs a y E AAA T F ee a ae Ar toes a namn E ae 4 T Ta L i Ta cf pe al L a rh a 2 anil a e e pE Wi y ere A T F D gee a ii T A F Byl Ee ij m 5 Lo 1 FE par a i i te fer a F a r d y he ae ll F A E i n 98 C 2 PROJECTED COORDINATE SYSTEMS FOR LOCAL AREAS APPENDIX C SOME COMMON CRS DEFINITIONS C 2 Projected Coordinate Systems for Local Areas NAD 83 New York Long Island ft US EPSG 2263 The State Plane zone that covers Long Island and New York City is used by all NYC agencies that produce GIS data An alternate projection EPSG 32118 represents the same zone but uses meters instead of feet Many city county and state agencies in the US produce data in their specific state plane zone proj 1cc tlat_1 41 03333333333333 lat_2 40 66666666666666 lat_0 40 16666666666666 lon_0 74 x_0 300000 0000000001 y_0 0 ellps GRS80 datum NAD83 to_meter 0 3048006096012192 no_defs NAD 83 UTM Zone 18N EPSG 26918 An alternative to State Plane that is better for larger regions and that is applicable outside the US satellite or ortho imagery is often provided based on the UTM zone where the tile is located UTM Zone 18N covers much of the east coast of the US An alternate projection EPSG 32618 uses WGS 84 as a datum instead of NAD 83 proj utm zone 18 ellps GRS80 datum NAD83 units m no
81. d promote its use http www osgeo org In this tutorial we will be using QGIS which was initially developed by a group of volunteers in 2002 as a simple GIS viewer but has evolved into one of the premier FOSS GIS packages The advantage of using QGIS for this tutorial it s free you can download it it runs on any operating system it is mature enough that it supports all essential GIS tasks plus many intermediate and advanced ones and it s relatively easy to use The disadvantage is that QGIS can t do everything that proprietary software can do yet and doesn t have the name recognition that software like ArcGIS or MapINFO possess There isn t as much in the way of documentation or tutorials for QGIS relative to the proprietary options but all of this has been changing In the last ten years there has been an increase in the number of workshops online tutorials and forums as the adoption of QGIS and other FOSS GIS software has grown and the software itself has become increasingly stable and sophisticated Open software tends to be modular rather than monolithic you often have several independent software ap plications to perform different functions rather than one large piece of software that does it all A typical FOSS GIS workstation may include several applications like QGIS for viewing data basic analyses map making generally working with vector data GRASS a more advanced GIS for doing analyses and modeling and for working wi
82. der row demog_data dbf LibreOffice Calc File Edit View Insert Format Tools Data Window Help ETE AA B O JE amp gt ijl Liberation Sans 110 a A 4 A E E E E A 32 o amp 2 y A B G D E F Ir GEOID C 14 GEOID2 C 5 GEOLABEL C 11 TOTPOP N 9 2 FEM18 49 N 8 2 PCTFEM N 6 2 8600000US10001 10001 ZCTA5 10001 21102 00 6810 00 32 30 8600000US10002 10002 ZCTA5 10002 81410 00 19583 00 24 10 8600000US10003 10003 ZCTA5 10003 56024 00 20058 00 35 80 6600000US10004 10004 ZCTA5 10004 3089 00 1083 00 35 10 8600000US10005 10005 ZCTA5 10005 7135 00 3272 00 45 90 8600000US10006 10006 ZCTA5 10006 3011 00 1317 00 43 70 8600000US10007 10007 ZCTA5 10007 6988 00 2033 00 29 10 8600000US10009 10009 ZCTA5 10009 61347 00 18568 00 30 30 6600000US10010 10010 ZCTA5 10010 31834 00 11016 00 34 60 PAN Sheet1 a a ae Sheet1 1 Default Sum 0 100 96 APPENDIX B TABULAR DATA DBF FILES Important things to note about DBFs You can view and create DBF files in spreadsheet programs such as LibreOffice or OpenOffice Calc and versions of Microsoft Excel between Office 97 and Office 2003 You can save text files and spreadsheets as DBFs in these programs by using Save As and selecting DBF as the option You can open or import DBF files with Microsoft Office 2007 through 2013 but you cannot save changes or create new files since Micr
83. e Data In this section you ll learn how to join an attribute table to a shapefile and map the attributes in that table Now that the tract boundaries are ready we need to associate them with census demographic data for those tracts in order to select the optimal neighborhoods for locating our shop F Donnelly Baruch CUNY 2015 35 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS 3 3 1 Steps 1 Open the data file Minimize don t exit QGIS for the moment Using your file manager browse to the data folder for part 3 Look for a file called p Emoc_pata xLs The data is stored in the older Excel 97 2003 format xls instead of xlsx that s still widely used Depending on what operating system you re using open this file with a spreadsheet package like Microsoft Excel or LibreOffice Calc double click and it should open in the appropriate program 2 Examine the data file The data file contains one row for each tract in NYC and several columns of attributes The first column contains the unique ANSI FIPS identifier used by the Census Bureau we ll use it to join this table to the shapefile The first three data columns are from the 2010 Census and contain the total population women aged 18 49 and percentage of the total population in that age and gender group The last two columns are from the American Community Survey ACS and represent an estimate of median household income and a margin of error
84. e Define current projection tool for that purpose You TRANSFORM projections for shapefiles that are defined and have a projection in order to convert them from one projection to another for a specific purpose Select the shapefile in the Map Legend and do a Save As to convert the shapefile from one projection to another QGIS Projection Handling When you open a new blank project in QGIS the default CRS is WGS 84 Then when you add your first layer your project automatically takes the CRS from that layer If you add subsequent layers that don t share the same projection QGIS will by default attempt to reproject them on the fly to match your other layers In general this is a bad practice Even if the software is successful at rendering the layers many selection and geoprocessing operations won t work as the files don t have a matching CRS and any distance or area calculations you make could be erroneous In this tutorial and in general I suggest that you know what CRS your layers are in and make sure all of the files you re using share the same CRS don t use the on the fly option I believe that this cuts down on confusion and helps avoid errors caused by mis aligning data layers and using systems of measurement that don t match For a particular project you can disable On the fly projection under Project gt Project Properties gt CRS tab If you want to change this setting globally for all your projects you can do so under Settings g
85. e borough layer is covering it up In order to show both layers you would have to move the stations layer on top of the boroughs Alternatively you could make the boroughs layer hollow by removing the fill which would allow the stations layer to be visible if it was on the bottom You would typically use a hollow fill for a polygon if you wanted to display it s boundaries on top of another polygon layer that has a fill 2 3 Exploring the Map View In this section you ll learn how to navigate the map view 2 3 1 Steps 1 Experiment with the Zoom tools Try each of the zoom tools in the Menu Bar e Pan move around the map by holding the left mouse button down and drag does not change the zoom e Pan Map to Selection move map to selected features without changing the zoom skip this one for now D i e Zoom In click to zoom in once draw a box to zoom in to an area or use the mouse wheel e Zoom Out works the same as the Zoom In tool e Zoom to Native Pixel Resolution will zoom to the optimal scale for rasters skip this one for now e 3 Zoom Full will zoom the window to the maximum extent of all visible layers e Zoom to Selection zooms to selected features skip this one for now e L Zoom to Layer zooms to the maximum extent of the feature currently selected in the ML e 4c Zoom last returns to your previous zoom e 4a Zoom next moves you forward to your next zoom if you ve already used zoom l
86. e data we ve used in our example categorical for nominal or qualitative data and others You also have the ability to filter color schemes based on desired output In the lower right hand corner of the map you can click on a scorecard that shows whether your choice is ideal for the color blind color printing photocopying and viewing on an LCD screen You should always choose color schemes based on what your final output format will be Colorbrewer gives you the option to export your color choices out as text where the text is some notation for representing color such as RGB or hexadecimal Number of data classes 3 howto use updates downloads credits Nature of your data 9 sequential diverging qualitative Pick a color scheme Multi hue Single hue Hiii iii iii iii Only show i 3 class BuGn colorblind safe D 2 ag print friendly HEX 5 m photocopy safe e5f5f9 99d8c9 2ca25f cities 2 D SU amp X o Eee JEJE S F Donnelly Baruch CUNY 2015 74 CC BY NC ND 4 0 4 5 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING 4 5 Designing Maps In this section you ll learn how to create a finished map that includes typical map elements legend title scale bar and source information 4 5 1 Steps 1 Adjust zoom Use the 2 Zoom in button and draw a box around the lower 48 states so they fit perfectly within the map window This will help insure that our map will i
87. e detail stored in the original file If the PDF takes too long to open or draw or the PDF file is too large you may want to consider checking the option to save the map as a raster within the PDF The problem with PDFs is they are stand alone SVG files are a vector format that can be embedded in other documents but support for them is uneven SVG may be the best option is you plan to import your map into a graphic design package to do more detailed work Image formats are raster based meaning that the image is composed of individual pixels or grid cells Rasters are designed for a specific scale zoom in too close and the image quality deteriorates as each individual cell becomes more distinct Rasters can stand alone or can be embedded in documents PNG files are an open format compressed raster Theyre a good alternative to JPG they have better image quality and are widely supported TIF files are a lossless uncompressed format use these only if you need to preserve the image at its highest quality these files get pretty big When exporting to a raster be sure to adjust the dpi dots per inch setting which will adjust the resolution of the image and affect it s size and quality When printing hard copy maps what you see on the screen is not exactly what you ll get on paper so be prepared to print test copies and go back and revise Because there are different screen resolutions and different printers in terms of print method and qualit
88. e information Hit the s add label button Click on the bottom of the map to add the generic label In the Label menu on the Item tab change the label to read Source US Census Bureau Voting and Registration in the Election of November 2012 Detailed Tables Change the font to size 8 Click on the label in the map and using the select move button move the label to the bottom center of the map and expand the size of the label box so the text appears on one line Add a label with author information Repeat the same step above to add a label with your information Map created by insert your name organization insert date Move this label underneath the source label Add a north arrow Hit the add image button Draw a box somewhere to the right of the US in the map In the Item properties tab expand the Search directories menu it may take a a few seconds for it to appear and scroll through the picture options in the Item properties and select a simple north arrow Move the arrow around on the map to get it centered and resize it to make it a bit smaller Add a scale bar Hit the add scale bar button Click below the map of the US to add the scale bar In the Item properties tab for the scale bar under Main properties change the Map from Map 2 the map for Hawaii to Map o the map for the lower 48 states Under the Units menu change the units from meters to feet and the label from kilometers to miles Under segments reduce
89. e joined to their corresponding features in a GIS file and mapped Tables are commonly stored in text files like txt or csv database files like dbf or in spreadsheets like Excel Pr y E Microsall Excel sludenis05 Country Albania Antiqua and Barbuda Australia Austria Bangladesh Barbados Belarus Belorussia 10 Be Belgiurn Hoa Bh Countrystuns Motes Ready e Geodatabases containers that can hold related raster vector and tabular data in one place They are good for consolidating and organizing data and many can be used for spatial queries and analysis Geodatabases can be desktop Microsoft Access mdb ESRI file geodatabases gdb Spatialite files sqlite or server based PostGIS ArcSDE E Donnelly Baruch CUNY 2015 6 CC BY NC ND 4 0 1 1 BASIC GIS CONCEPTS CHAPTER 1 DB Manager Database Table S ila E Tree E SpatiaLite B nyc_gdb_july2014 sqlite E Spatiallndex 6 a_boroughs a_colleges a facilities a_greenspace es a_hospitals e a_libraries namelsad pura Ny AN OVERVIEW OF GIS geometry Brooklyn Bronx Kings Bronx County Kings County MULTIPOLYGON MULTIPOLYGON Manhattan Queens New York Queens New York C Queens Cou MULTIPOLYGON MULTIPOLYGON Staten Island Richmond Richmond C MULTIPOLYGON am
90. e layer in the ML and choose the Toggle editing option Each feature will be outlined in red the red X s represent the individual vertices that each polygon is composed of Zoom in to the area around Puerto Rico Click the Select features button in the toolbar Click on Puerto Rico to select it On the Editor toolbar select the Delete selected button or go to Edit gt Delete Selected Confirm the deletion Zoom back out to see the rest of the US Hit the Edit button on the toolbar to toggle the edits off Save your edits Save your project Layers x ci 7 a Ei w we 3 Examine the voter data table Minimize QGIS Use your file browser to go to the part 4 data folder Find the file called TasLeo4ga xts Double click on the file to open it in Excel The workbook has two sheets The first sheet Table 4a is the original data The second sheet Vote has been reformatted from the original so that its appropriate for importing and joining in QGIS Take some time to note the differences between the two sheets The tables show the total population the total population who are US citizens the total number of registered voters and the number of people who voted in Nov 2012 All totals are rounded to thousands i e the population of Alabama is recorded as 3 594 which is 3 594 000 Different proportions were calculated for each group and since the data is sample based a margin of error is provided for the percentages
91. e sure to examine your data to see what the distribution looks like It also helps to become familiar with the places you are studying so you can draw on your more qualitative experiences to make decisions and perform a reality check on your observations Some Basic SQL The Select features using an expression menu allows you to build complex queries for selecting features QGIS and most GIS packages use the Standard Query Language SQL that s used when working with databases Some tips e The boolean operator AND is exclusive use it to select features that meet all of the criteria the statement per_fem gt 24 6 AND PNTCNT lt 3 will only select features where both criteria are met e The boolean operator OR is inclusive use it to select features that meet one of the criteria the statement per_fem gt 24 6 OR PNTCNT lt 3 will select features that meet the first criteria or the second one or both e Your statements must be explicit for every operation you must include the field that is part of the operation PNTCNT gt 2 AND PNTCNT lt 4 is a correct statement PNTCNT gt 2 AND lt 4 will yield an error because you didn t specify the field for the second operator F Donnelly Baruch CUNY 2015 AQ CC BY NC ND 4 0 3 6 DRAWING BUFFERS AND MAKING SELECTIONS CHAPTER 3 GEOGRAPHIC ANALYSIS e Statements can be written more than one way In our example above PNTCNT gt 3 and PNTCNT gt 4 would yield the same result s
92. ecific countries or other continents proj aea lat_1 20 lat_2 60 lat_0 40 lon_0 96 x_0 0 y_0 0 ellps GRS80 datum NAD83 units m no_defs Although difficult to see at this scale visually Albers Equal Area Conic on the right looks more compact east to west versus Lambert Conformal Conic on the left C 4 Global Projected Coordinate Systems Robinson EPSG 54030 A global map projection used by National Geographic for many decades The Robinson map is a compromise projection it doesn t preserve any aspect of the earth precisely but makes the earth look right visually based on our common perceptions proj robin 1on_0 0 x_0 0 y_0 0 ellps WGS84 datum WGS84 units m no_defs Mollweide EPSG 54009 A global map projection that preserves areas often used in the sciences for depicting global distributions on small maps proj moll l1on_0 0 x_0 0 y_0 0 ellps WG584 datum WGS84 units m no_defs Visually the difference between Robinson on the left and Mollweide on the right is apparent O O Lo E ET O A A E a hi e CBF i ae a A p ae y ME A ot i oo qn a de a a pa ara le dir pe F F E E cae E i T Le Oe Sig s i a E a i i a PA r 57 y a pe E j Po o oa a as at L r ae a T r re T ul Y i F K se h i A Lt 4 o oth r iE ate a fi fi El n MaE i p aa P BB TT a TE kl f oe A pe tS ek ME ES E P a h i i A T t i h rt id Le 7 pi 0 ik q h ns F a gt
93. eighborhoods that met our criteria To isolate the former within the latter we ll use the Intersect tool On the menu bar go to Vector gt Geoprocessing tools gt Intersect Choose TRACTS_ SELECTED as the input vector layer Choose BUFFERS_suBwaY as the intersect layer Make sure the box that says Add result to canvas is checked Browse and save the new result to your part 3 data folder as sELECTED_AREAS Hit OK Close the Intersect menu Z Intersect amp x Input vector layer tracts_selected z Use only selected features Intersect layer buffer_subway Use only selected features Output shapefile c_data part3 selected_areas shp Browse X Add result to canvas 5 Clean up your map Drag the new SELECTED_AREAS layer so that it is directly above the BoroucHs layer in the ML Check the nyc_FAcILITIES AND NYC_GREENSPACE layers to turn them back on and uncheck the suBway_sTATIONS BUFFER_SUBWAY AND TRACTS_SELECTED layers to turn them off so you can see the end result more clearly We could refine our analysis a bit more by subtracting the greenspace and facilities areas that intersect our areas of interest since we couldn t build a store on this land For now overlaying these land uses on top of our areas of interest should suffice Select the seLecTED aretas layer in the ML then hit the zoom to layer button so our areas of interest are maximized within the map window The new SELECTED_AREAS layer shows you the areas t
94. ement window will update with distances in meters and kilometers If you click on the southern tip of Manhattan it will lock the line segment and allow you to draw a second segment from the second point Hit the Close button when you ve finished experimenting Z Measure OTF off eX Segments meters 20 849 059 Total 20 849 km New Close Help E 4 Change your measurement units Go to Settings gt Options gt Map Tools tab In the Measure Tool section under Preferred measurement units select the feet radio button Hit OK Try the measuring distance tool again and your units will be in feet and miles 2 3 2 Commentary Options Menu The Settings gt Options menu allows you to customize many aspects of QGIS Don t like the default option of an orange measuring line or yellow for selected features Change it here You can also change the default standard colors in the symbology menu control how sensitive the identify tool is and specify how QGIS should handle conflicting coordinate reference systems for layers If you re not sure what an option is leave it alone and stick with the default These options are global and apply to this installed instance of QGIS If you wanted to modify properties for just one specific project you can do that under Project gt Project Properties f Options Map Tools X NS General v Identify System Search radius for identifying featur
95. es F Donnelly Baruch CUNY 2015 21 CC BY NC ND 4 0 2 5 ADDING RASTER DATA CHAPTER 2 EXPLORING THE INTERFACE 2 5 Adding Raster Data In this section you ll get a very brief introduction to raster data For a fuller treatment you can use the tutorial Working with Raster Data in QGIS that was created as an addendum to this workbook see the Commentary at the end of this section for details 2 5 1 Steps 1 Add raster data Hit the Y add raster layer button on the toolbar Browse to the data folder for part 2 select the DRG_CENTRAL_PARK TIF file and add hit open Once the layer is added drag it to the bottom of the ML 2 Explore raster map Select the DRG_CENTRAL_PARK layer in the ML Right click on the layer and select Zoom to best scale 100 Uncheck the Boroucus layer in the ML to turn it off Select the GREENSPACE layer in the Map Legend Double click to open the Layer Properties and go to the Style tab Drag the transparency slider to 30 and click OK Explore the area of the map around Central Park and note how the raster layer lines up with the other layers 7 QGIS 2 6 0 Brighton part2 all xX Project Edit View Layer Settings Plugins Vector Raster Database Help DEBRA Me eeanpp abe ab aby abe i f O d a e f me E Browsen Layers gt ES D E oordinate 989694 219724 cale 1 11 473 X Render 3 View raster properties Double click on the raster layer in the ML to open it s properties Select
96. es and displaying map tips 2 00 mm lt gt Note Specify the search radius as a percentage of the map width f Data Sources Highlight color GGG 7 Buffer 0 50 mm gt Minimum width 1 00 mm Rendering Y Measure tool y Colors Rubberband color Co J4 E Canvas amp Legend Decimal places 3 Keep base unit Preferred measurements units Meters Feet N Nautical Miles Degrees Preferred angle units Degrees Radians Gon Y Panning and zooming Mouse wheel action Zoom to mouse cursor sy LA 4 Zoom factor 2 0 Locale o w Predefined scales oe Network 1 1000000 1 500000 1 250000 1D ME yA E J gt al F Donnelly Baruch CUNY 2015 18 CC BY NC ND 4 0 2 4 EXPLORING FEATURES CHAPTER 2 EXPLORING THE INTERFACE 2 4 Exploring Features In this section you ll learn how to explore and interact with features in the Map View and Attribute table 2 4 1 Steps 1 Identify features Hit the identify features button in the toolbar Select the Boroucns layer in the ML Click on Manhattan Manhattan is highlighted and information about that feature is displayed Click on The Bronx to change the selection Note if the Identify Results window is embedded below the layers menu you can drag it to the middle of the window to un dock it 2 Identify features from a different layer Make the suBway_sTATIONS layer the active layer by selecting it in the ML Click on any station in the map
97. esults and Add result to canvas Hit the browse button to save the new shapefile in your part 3 folder as BUFFER_sUBWay Hit OK Close the buffer menu when you re finished Z Buffer s Y 28 Input vector layer subway_stations Use only selected features 4 Segments to approximate 5 O Buffer distance 1760 Buffer distance field stop_id X Dissolve buffer results Output shapefile ic_data part3 buffer_subway shp Browse X Add result to canvas 0 Ok Close 3 Re arrange layers To see everything more clearly arrange the layers in the ML in this order from the top SUBWAY_STATIONS BUFFER_SUBWAY The two layers at the bottom of the ML should be TRACTS_SELECTED and BOROUGHS and the layers in between should be unchecked and off You may want to assign different colors to the buffers to make them more visible Explore the map you ll see circular zones in a 1 3 mile radius around each subway station The boundaries between each buffer zone are merged where zones intersect as a result of checking the dissolve results box F Donnelly Baruch CUNY 2015 50 CC BY NC ND 4 0 3 6 DRAWING BUFFERS AND MAKING SELECTIONS CHAPTER 3 GEOGRAPHIC ANALYSIS Layers Y aag X O subway stations X buffer_subway O coffee_shops facilities greenspace x tracts_selected x boroughs 4 Isolate areas within selected tracts Ultimately we are interested in the areas around subway stations that are within the n
98. ew copy with a different project name Save As saves you the effort of starting from scratch if you have an existing project that you can use to branch off from When you remove a layer from a project you re just severing the link between a particular project and that data you re not actually deleting the data itself 3 2 Geoprocessing Shapefiles In this section you ll learn how to process a shapefile to prepare it for analysis This is a common GIS task normally when you download publicly available shapefiles you ll have to do some processing to make them usable for your projects You ll also learn how to use the Browser to work with your files You ll be processing a boundary file for census tracts which we ll use to approximate areas within neighborhoods Census tracts are statistical boundaries created by the US Census Bureau to represent census data for small areas they re designed to have an ideal size of 4 000 residents The file was downloaded from the US Census TIGER Line Files and re projected to match the coordinate reference system of our existing features 3 2 1 Steps 1 Add the tracts shapefile using the Browser The browser allows us to see our file system within QGIS and to add data directly to our project instead of using the toolbar buttons to add Vs vector or Y raster data The browser has folders that represent hard and external drives as well as icons for connecting to various geodatabases and web services Tab over from t
99. f the earth at the edges are best for general or thematic use F Donnelly Baruch CUNY 2015 63 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING Every continent and country has a preferred map projection or set of projections that is appropriate for each area based on its size and shape Look at atlases or pre existing maps to get an idea of what these are Albers Equal Area Lambert Equal Area and Lambert Conformal are common and are adjusted to focus on specific continents or countries Orthographic projections are used to map polar areas CRS Definitions Several formats have been created for recording the definition of projections There s the Open Geospatial Con sortium s Well Known Text Format OGC WKT as seen in the example we worked through the Proj4 format and prj file format created by ESRI To look up CRS information you can use the Spatial Reference website at You can use that site to get the proj4 format for creating custom projections if QGIS lacks a particular projection in its library When you open a prj file and look at the definition you ll see the elements that make up the GCS projection datum spheroid as well as units of measurement and origin information PROJCS North_America_Lambert_Conformal_Conic GEOGCSL GCS_North_American_1983 DATUML North_American_Datum_1983 SPHEROID L GRS_1980 6378137 298 257222101 PRIMEM Greenwich 0 UNIT Degree 0 0174532925199432
100. features QGIS is able to take data stored in standalone DBF and join them to DBFs affiliated with shapefiles based on a common ID code using relational database techniques SQL Join statement The DBF file has a few advantages over the other formats Unlike text files data in DBFs are stored in a tabular format Columns in DBF files have data types text numbers etc that can be easily modified and that QGIS can interpret without any problems Since they are a basic format many import problems that can occur when working with Excel files are less common The big disadvantage of DBF files is that MS Excel stopped supporting the format in 2007 so most users can t readily create or modify DBFs unless they download additional software The free and open source spreadsheet programs LibreOffice and OpenOffice Calc fully support the DBF format and have become the standard spreadsheet programs for working with these files most relational database programs also support DBFs as an export format The figure below depicts a DBF file in LibreOffice Calc available for free download from https www libreoffice org The first row contains the column name and data types For example GEOLABEL is a text column C for character with a width of 11 characters TOTPOP is a numeric column N for number with a width of 9 characters and a precision of 2 numbers right of the decimal place You can change names type width and precision simply by altering the hea
101. fy Hit OK to re map your data in this scheme The natural breaks method classifies data based on the location of clusters of values or conversely in gaps or breaks in the data range which is less arbitrary than equal intervals or quantiles If you select strates Lcc in the ML right click and open the attribute table and sort by Vote_PerVotCitz you can look at the distribution of the data and see how the formula made the breaks Close the table when you re finished 47 8 55 9 7 61 9 67 6 17 x X 55 9 61 9 17 x x 67 6 75 9 10 5 Save your project At this point save your project For our map we ll stick with the natural breaks method but read the commentary below for an explanation of each method and it s advantages and disadvantages E Donnelly Baruch CUNY 2015 72 CC BY NC ND 4 0 4 4 CLASSIFYING AND SYMBOLIZING DATA CHAPTER 4 THEMATIC MAPPING 4 4 2 Commentary Data Classification and Color Schemes The purpose of a thematic map is to communicate a message about the data If a map uses too few classes then the data is too generalized and meaningful patterns can be hidden If a map uses too many classes then a pattern becomes difficult to detect because there is too much detail It is difficult for the human eye to distinguish between too many colors or variations of color Generally speaking it is a good idea to use 3 to 6 classes and ideally 4 or 5 When choosing the number of clas
102. h CUNY 2015 32 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS Census Tracts Statistical areas created by the US Census Bureau to have approximately 4 000 residents with a range of 1 200 to 8 000 Tracts can be used for analyzing patterns within counties cities and neighborhoods and can be aggregated to create neighborhood like areas many cities create official neighborhood or sub municipal areas based on tracts The NYC Department of City Planning has taken the 2 000 plus census tracts in the city and aggregated them to create 195 Neighborhood Tabulation Areas NTAs for presenting and publishing census data Dataset availability 2010 Census and 5 year ACS The choice of a geographic unit is an important decision it s often a balance between the availability of data for an area the suitability of the unit for the analysis the amount of work that has to be invested in processing and analyzing the data and the final outputs that will be created tables charts maps to explain the data We used tracts for this exercise because the demographic data availability for them is good there is a work able number of them in the city approximately 2 000 and they are commonly used for studying distributions within urban neighborhoods Other geographic areas present different trade offs Government agencies typically combine census tracts into larger areas to represent neighborhoods the City of New York has done
103. he attribute table for the stares layer you ll see it has a column called STATE that contains the same code 5 Join the data to the shapefile Select stares Lcc in the ML double click and open the Joins tab in the properties menu Hit the green plus sign to add a new join Vore is the join layer ANSIFIPS is the join field in that layer and STATE is the target field in our shapefile Instead of taking all of the columns check the box to choose fields and take these five USPS PerRegCitz PRC_MOE PerVotCitz and PVC_MOE Check the Custom field name box and delete Vote_ so that the option is blank Click OK Then make sure to click OK or Apply on the properties menu Close the menu select strates Lcc right click and open the attribute table You ll see that the data that we ve selected has been added Close the table Save your project Y Layer Properties states_lcc Joins Z Add vector join x N General Join layer Join layer Vote v Style Join field ANSIFIPS v Labels Target field STATE X EE Fields Rendering X Cache join layer in virtual memory _ Create attribute index on join field w X Choose which fields are joined E Display RO Actions X PerRegCitz x PRC_MOE TotVote PerVotPop PVP_MOE X PerVotCitz x PVC_MOE o lt Joins Diagrams i Metadata w X Custom field name prefix 6 To save as or not to save as If we wanted to permanently fuse the voter data table to our shapefile we
104. he Layers to the Browser menu use the plus buttons to expand the folder tree where your project files are stored and drill down to the part3 folder Select the tracts layer which is called TL_2012 36_TRACT_NYSP SHP You can either right click and choose the option to add it to your project or you can hold down the left mouse button and drag it into the Map Window Browser T Gad E Lo gis_prac_data part2 b_boundary shp 2 boroughs shp drg_central_park tif drg_trees tif J facilities shp greenspace shp L subway_stations shp E Je part3 demog_data dbf nyc_coffee txt nym_water shp 2012 36_tract_nysp shp 83 2 gz_2010_us_040_00_20m sf a O aP Browser Layers F Donnelly Baruch CUNY 2015 28 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS 2 Organize layers By default the new layer is drawn over top of the currently selected layer if no layer is currently selected it is drawn on top of all of them Tab from the Browser back to the Layers menu Select the Tracts layer in the Map Legend ML and drag it to the top of the legend With the tracts layer active in the ML hit the zoom to layer button You ll see the tracts layer covers all of NY state but we only need tracts for NYC We ll do some operations and create a new file that just has the NYC tracts Select the B_BOUNDARY layer in the ML and hit the zoom to layer button Select the tracts layer in the ML and drag
105. he box at the top that says Enable on the fly CRS transformation then hit OK Save your project Project Properties CRS L P x Enable on the fly CRS transformation tecently used coordinate reference systems 7 Re project the countries layer Lets see what happens now when we re project the countries layer Select COUNTRIES_MOL SHP in the ML right click and choose Save As Hit the Change button beside CRS In the CRS Selector window type Robinson in the Filter box Select World Robinson EPSG 54030 in the results and click OK Back in the Save as window verify that the Add saved file to map box is checked and Browse and save the file in the part 4 folder as COUNTRIES_ROB 8 Reset the projection for the project In this case the COUNTRIES_ROB SHP layer is added to our map but fails to draw This is the signal that this layer doesn t match our existing Mollweide layer Select counTrIES_MOL in the ML right click and remove it Select COUNTRIES _ROB sHP in the ML right click and choose Set Project CRS from Layer Then hit 23 Zoom to Full Extent We should see our newly projected layer in Robinson and the EPSG Code for the window is 54030 Save your project Layers X gt Y a 3 x countries rob Browser Layers 8 Coordinate 12223020 11088884 Scale 301 548 573 y Render EPSG 54030 A Current CRS World_Robinson 9 Avoid the Define Current Projection pitfall When transforming
106. he box that says Custom field name prefix and remove Sheeti_ so that the option is blank This will preserve F Donnelly Baruch CUNY 2015 36 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS the original column names from the spreadsheet Keep the other defaults and hit OK Wait a few seconds for the join to complete and appear in the Joins tab then make sure to hit either Apply or OK in the properties menu to make the join stick Then close the menu and right click on TRacts_Nyc_LAND in the ML and open the attribute table Scroll over to the right and you ll see all of the layers attributes and the data that is stored in the Excel file Close the attribute table fa G Wal Add vector join Eg 25 Join layer Sheetl z Join field id z Target field GEOID z X Cache join layer in virtual memory Create attribute index on join field v Choose which fields are joined 3 D a 5 g CO 4 gt w X Custom field name prefix 6 Make the join permanent Our data table is dynamically joined to our shapefile and if we save the project the join will be saved within the project At this point we could map the joined data but we won t be able to perform a lot of other operations unless we make the join permanent so that the data is fused to the shapefile as new attributes To do this we simply have to save this shapefile as a new one So select TRACTS_NYC_LAND in the M
107. he records for these E Donnelly Baruch CUNY 2015 44 CC BY NC ND 4 0 3 4 PLOTTING COORDINATE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS stores were subsequently added referenceUSA Home AboutUs Data Quality TakeaTour Customers ContactUs FAQs Resource Center Library Locator Available Databases U S Businesses Database Quick Search Custom Search Expand All Select All VIEW RESULTS Company Name 4a To start your search hood i UPDATE COUNT Executives Click on the headings to the left to start your search If you are uncertain what to search for look for Search Tips within each RECORD COUN Business Type section to help you along the way 15 910 933 O Geography To further customize your search select the Record Type you COUNT would like to search below to ensure you get the records you are 1 337 679 Phone looking for more info Business Size Record Type Search Tips i Expand CLEAR SEARCH Ownership Back To Top Financial Data Special Selects There are also free public sources for downloading coordinate data that you can use to create features for natural lakes mountain peaks parks etc and human made cities airports schools cemeteries etc features such as the USGS Geographic Names Information System for US features and the NGA s GEOnet Names Server for international features The subway stations layer was created from coordinate data provided by the NYC MTA If you have batches of
108. he web while others can only be accessed by making arrangements with the geospatial data librarian F Donnelly Baruch CUNY 2015 90 CC BY NC ND 4 0 5 3 ADDITIONAL CONCEPTS AND APPLICATIONS CHAPTER 5 GOING FURTHER 5 3 China Data Center provincial county and prefecture boundaries features and census data for China Baruch College only CUNY Campus Facilities campus buildings and properties for the City University of New York public DRG s for NYC Metro scanned and georeferenced USGS topographic maps for the NYC metro area public ESRI International data features for the world Canada Mexico and Europe some public others CUNY only ESRI USA data features for the United States some public others CUNY only MapPLUTO 2008 tax parcel and real estate datasets for NYC public NYC Geodatabase geodatabases of NYC neighborhood features and census data public NYC Transit Spatial Layers city and metro area transportation features including buses subways and trains public NYC Transportation Data city and metro area transportation features including buses subways trains and truck routes Baruch College only ReferenceUSA Historical records for individual US businesses with XY coordinates from 1997 to 2014 Baruch College only US Census Population Centroids point features representing the center of a population s distribution for different legal and admin areas public Additional Concepts and Applications
109. hor may NOT use it for commercial purposes and may NOT modify the work e You MAY link to this document download it print it out and distribute it in print or electronically via email or internal networks but e You may NOT copy and re host this material on another website without permission Objectives Participants will be able to bring both the tools and the knowledge they gain from this workshop to enhance their projects and the organizations they work for Specifically this workshop will enable participants to e Add data to GIS software and navigate a GIS interface e Perform basic geoprocessing operations for preparing vector GIS data Convert text based data to a GIS data format Conduct geographic analyses using standard GIS tools and vector data Create thematic maps using the principles of map projections data classification symbolization and carto graphic design Locate GIS data on the web and consider the merits of different data sources Demonstrate competency with a specific GIS package open source QGIS Identify other GIS topics tools and techniques for analysis data formats raster vector and software open source and ArcGIS to pursue for future study Outline Chapter 1 General introduction and overview of GIS Chapter 2 Introduction to GIS Interface learn how to navigate the interface adding data layering data symbolization changing zoom viewing attributes viewing attribute table making basic
110. http www census gov geo maps data data tiger line html The tracts used in this tutorial were downloaded from the Census TIGER site as were most of the other files used in this exercise The borough file is a subset of the TIGER county file for New York State while the facilities and green space layers are aggregations and selections from the TIGER landmarks file for each of the five counties All three layers were geoprocessed for this tutorial to convert legal boundaries to land boundaries using a subset of the TIGER water features F Donnelly Baruch CUNY 2015 33 CC BY NC ND 4 0 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS 5 www census gov cgi bin geo shapefiles2012 main E O DuckDuckGo P A U S Department of Commerce C United States census People Business Geography Data Research Newsroom Home Blogs Ab Bureau 2012 TIGER Line Shapefiles Select the layer you are interested in from the dropdown menu and click TIGER Line Shapefiles Main submit and you will then see the geographic areas for which that layer is available Documentation Select a layer type Access our FTP site for additional downloading options ZIP Code Tabulation Areas v Source US Census Bureau Geography Division We were able to add the tracts layer directly to our project because it shares the same geographic coordinate system as our other layers the State Plane system that s appropriate for the
111. ince the number of coffee shops is saved as an integer e If your query includes text rather than numbers all text must be surrounded by quotes otherwise you ll get an error COUNTYFP 36081 will return all tracts in Queens You can also use wildcards COUNTYFP LIKE 3608 will return all the tracts in Queens 3608r and Staten Island 36085 3 6 Drawing Buffers and Making Selections One of the primary strengths of GIS is the ability to layer different features and to combine or extract information to create new features In this section you ll learn how to create buffers around features and to deduct areas from selections For our example we want to target areas that are near subway stations since these represent traffic and commercial activity We ll identify these optimal areas within the census tracts that met our conditions To provide geographical context for our selected areas we ll connect to a web mapping service WMS 3 6 1 Steps 1 Activate and de activate layers Hit the check boxes beside the susway_stations layer to turn it on and uncheck the GREENSPACE FACILITIES and COFFEE_SHOPS layers to turn them off 2 Create buffers On the menu bar go to Vector gt Geoprocessing tools gt Buffers Specify the suBway_sTATIONS as the input vector layer For the buffer distance type 1760 this is in feet and represents approx 1 3 mile see commentary below for explanation Check the two boxes that say Dissolve buffer r
112. interested in you ll find more country specific layers and they will be processed in a way that is readily compatible for mapping attribute data from that country Most countries have one or two agencies that will provide the bulk of the country s GIS data a statistical agency responsible for the census or a mapping agency responsible for surveying In the US you could go directly to the US Census Bureau or the USGS to download data or you could visit the central data gov repository In Canada you could visit Statistics Canada directly or visit the Geogratis repository Some countries provide one central source Australia whereas other countries may provide limited or no data State Provincial You may be able to visit a country level source like the US Census Bureau to get state county or zip code boundaries for the entire state or you can visit a state level agency to get more specialized datasets for that state Some states will have state government portals where you can access all data for a state others may cooperate with a college or university located in that state to provide data via the university s portal In addition to centralized portals individual departments or agencies may also provide data directly road and transportation layers may be provided by a state department of transportation or may be provided through the state s central portal State agencies are also the most likely source for aerial photography County Cit
113. is a count not a survey of the population and continues to be useful for making historical comparisons providing a baseline for creating estimates for doing analysis below the census tract level and for providing exact counts when estimates aren t suitable F Donnelly Baruch CUNY 2015 38 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS A third data product Population Estimates is published annually and is created using demographic calculations as opposed to a count or survey based on births deaths and migration Basic estimates total population age gender race and housing units are published for states counties incorporated places and metropolitan areas File Edit View History Bookmarks Tools Help American FactFinder F H amp factfinder2 census gov faces nav jsf pages index xhtml E Cc DuckDuckGo P amp 12 a A U S Census Bureau FactFinder Feedback FAQs Glossary Help MAIN SEARCH WHAT WE PROVIDE USING FACTFINDER English Espanol Your source for population Py x lt E7 A iaa housing economic and ar 4 g geographic information Search using the options below Topics p age income year dataset American FactFinder works with Mozilla Firefox 3 6 and NEST SONEN Microsoft Internet Explorer 7 Other browsers may not Find Census data b Geographies gt perform as expected y z entering a street address states counties pl
114. is selected Note you can select multiple records from the table by holding down the CTRL key and selecting records one by one or select a range by selecting a record hold the SHIFT key and select the last record Z Attribute table subway_stations Features total 490 filtered 490 selected 1 bal x J i amp BEB S PAE Ed stop_id stop_name trains complex_id multi_st A15 125 St ABCD mn013 NULL 36061 224 135 St 23 mn014 NULL 36061 A14 135 St BC mn015 NULL 36061 416 138 St Grand Conco 45 bx001 NULL 36005 132 14 St 123 mn018 x 36061 F Donnelly Baruch CUNY 2015 19 CC BY NC ND 4 0 2 4 EXPLORING FEATURES CHAPTER 2 EXPLORING THE INTERFACE 5 Select a feature from the map With the susway_stations layer still selected in the ML hit the EX select feature button in the toolbar Then select the station that is southwest of 137 St City College and just east of the northern boundary of Riverside Park Hit the open attribute table button At the bottom of the table hit the filter drop down menu and choose the option to Show Selected Features This reveals the record for the 125 St station for the 1 Train this is the station that you ve selected in the Map View These two steps demonstrate that the table and map are linked and you can select features in one and display them in the other Note you can select multiple features by holding down the CTRL key and clicking on feature
115. is served by existing coffee shops You can use the Vector gt Analysis Tools gt Distance matrix to calculate the distance from each station to the closest shop or the average distance from each station to all shops F Donnelly Baruch CUNY 2015 56 CC BY NC ND 4 0 Chapter 4 Thematic Mapping The goal of this chapter is to introduce you to map layout and design as well as to some additional data processing techniques You will also grapple with coordinate systems and map projections which are central components under lying GIS You ll learn about cartographic representation and design and the practical implications of choosing how to classify and represent your data The goal of this particular exercise is to create a stand alone thematic map to show the distribution of voters by state in the November 2012 elections in the United States The data we ll use was collected as part of the Current Population Survey and was compiled by the US Census Bureau at http www census gov hhes www socdemo voting index html However before we focus on this goal we ll experiment with a global layer to get some practice with working with coordinate reference systems CRS We ll use a generalized layer of countries downloaded from Natural Earth at http www naturalearthdata com 4 1 Transforming Map Projections I This section will show you how to transform a file from one coordinate reference system CRS to another and will generally cover
116. j4 definitions for these projections in order to custom define them A brief list of common projections and definitions is included in the appendix of this tutorial Defining Undefined Projections All shapefiles have a CRS and were created based on a particular one but in some cases you may download or come across a file where the projection information for the shapefile the prj is missing In order to use the shapefile you will have to define the projection and create a prj for it so that the software will know how to render and layer it properly To do this you ll have to go back to the website or source and look for some metadata that will tell you F Donnelly Baruch CUNY 2015 64 CC BY NC ND 4 0 4 2 TRANSFORMING MAP PROJECTIONS II CHAPTER 4 THEMATIC MAPPING what CRS the file is in The metadata could be listed on the download website in a README or narrative file that ac companies the shapefile or in an XML file accompanying the shapefile that was written based on metadata standards Once you know what the projection is you can go to Vector gt Data Management Tools gt Define current projection You can assign the projection from the QGIS databases of projections or you can import it from an existing shapefile that has the proper projection Note that defining a projection is DIFFERENT from transforming one You DEFINE projections for shapefiles that are undefined in order to tell the software what projection it is in Use th
117. ject From Existing One This section will show you how to create a new project from an existing one and will set the working environment for the rest of part 3 3 1 1 Steps 1 Open project Launch QGIS Hit the open project button or go to File gt Open Project Browse through your folders to the QGIS project file you created for part 2 and select it to open it 2 Save Project As Once your project has loaded hit the Ed save project as button or File gt Save Project As Browse to the data folder for part 3 Save the project in that folder as parT3 Q6s Hit save You ve now saved a new copy of your old project and are currently working in this new copy you can tell by looking at the title at the top of the window where the project name is listed We will work with this new project parT3 qcs for this part of the tutorial Z QGIS 2 8 2 Wien part3 3 Remove layers We don t need the raster layers for this exercise Select the DRG_CENTRAL PARK layer in the Map Legend ML Right click on the layer in the ML and select Remove Do the same for the DRG_TREES layer 27 3 2 GEOPROCESSING SHAPEFILES CHAPTER 3 GEOGRAPHIC ANALYSIS 4 Zoom out and save Hit the 42 zoom to full extent button to zoom out to the full extent of your layers Then hit the save button 3 1 2 Commentary Saving Projects and Removing Layers Use the Save button to save the current project and the Save As button to save the current project as a n
118. known as the Map View 6 Status Bar shows the current scale of the map view the coordinates of the current position of the cursor and the coordinate reference system CRS used by the project Z QGIS 2 6 0 Brighton E X 3 x ay v a y P 1 1 yor JO po y g f B RR Browser 2 Oaa Y E Hs Home E Favourites 3 5 de C y uperdat log y _Workspace apps 10463 10467 1 a x EJ oe Layers Bx VEG ps 104619 10462 b_zctas_2012biz_ind aiT 10032 R subway_stations 10039 10456 reenspace L g ES 10031 facilities a zctas 10030 1 0 8 0 10027 10037 8 0 16 4 gt 10454 16 4 24 1 00025 0 410035 gt o Bx An 10029 11357 39 1 100 0 1002 E os 411370811356 Coordinate 1046154 249822 Scale 1 171 473 y Xi Render EPSG 2263 A e Want to turn a toolbar off Wondering where a toolbar went If you right click on a blank area of either the Menu Bar or the Toolbar you ll get a list that shows all of the toolbars as well as the Map Legend and Map Overview You can check and uncheck items to turn them on and off F Donnelly Baruch CUNY 2015 12 CC BY NC ND 4 0 2 2 ADDING VECTOR DATA CHAPTER 2 EXPLORING THE INTERFACE e Cant figure out what a button means or does If you hover over a button a small window appears that displays the name of the button If you select the h get a brief explanation of what it is what s this
119. l add them back to our project First Fl save your project Then hit the New project button to get a blank workspace 3 Launch the delimited text layer menu Hit the Add delimited text layer button on the tool bar Under File Name Browse to the Part 3 folder and select nyc_corree and hit Open This will populate the menu screen Under File format select the Custom delimiters radio button and check the box for Tab Under Record Options verify that the First record has field names box is checked Under Geometry definition the Point coordinates radio button should be selected Under the X field drop down select LONG the X coordinate is always longitude Under the Y field drop down select LAT the Y coordinate is always latitude Hit OK G Create a Layer from a Delimited Text File P x File Name X FrankDocs GIS_Practicum gis_prac gis_prac_data part3 nyc_coffee tt Layer name nyc_coffee Encoding UTF 8 File format CSV comma separated values Custom delimiters Regular expression delimiter Comma X Tab Space Colon Semicolon Other delimiters Quote Escape Record options Number of header lines to discard 0 X First record has field names Field options Trim fields Discard empty fields Decimal separator is comma Geometry definition Point coordinates Well known text WKT No geometry attribute only table X field LONG vy Y field LAT z DMS coordinates Layer settings Use spatial index Use subset index Watch file CONAME ADDR
120. learning a specific application or process followed by commentary that explains various facets of the process Steps are enumerated and begin with italicized text a DY stop sign appears at the conclusion of a series of steps to clearly delineate where the steps end and the commentary for that section begins Menus tabs and items are capitalized if they appear capitalized in the interface Images of toolbar buttons appear in the text whenever they are referenced The names of files and layers appear in SMALL CAPS TEXT Urls for websites appear in typewriter text E Donnelly Baruch CUNY 2015 2 CC BY NC ND 4 0 Changes From Previous Manual This manual 6th edition has been updated from the previous manual 5th edition with relatively minor revisions as the differences between QGIS 2 8 Wien and QGIS 2 6 Brighton for doing basic GIS tasks are not that great The primary reason for doing revisions was that QGIS 2 8 was released as a Long Term Service LTS version which means it will continue to be supported for a year even as newer version of QGIS are rolled out Updating the manual seemed justified since 2 8 will have greater longevity Its also important to note that the site where the manual and data is hosted has changed The new address is https www baruch cuny edu confluence display geoportal GIS Practicum Specific changes Chapter 1 No changes Chapter 2 Updated the subway stations layer to reflect the most rece
121. lities boroughs H X drg_central_park x b_boundary Browser Layers F Donnelly Baruch CUNY 2015 23 CC BY NC ND 4 0 2 6 SAVING YOUR PROJECT CHAPTER 2 EXPLORING THE INTERFACE 2 5 2 Commentary Raster Data Raster layers differ from vector layers in many ways including composition continuous surface of pixels versus discrete geometric areas file formats many raster formats versus relatively few vector formats resolution optimal scale for raster layers matters more than vector layers size raster files tend to be much larger and attribute tables raster layers do not have attribute tables the color of individual pixels denotes feature values Given the differences in format the tools for working with vector and raster layers are distinct Many geographic objects are represented in raster formats including satellite imagery aerial photography paper maps that have been scanned and digitized and imagery that has been interpreted to represent value added data that does not conform to political boundaries such as land use and land cover temperature and population density The raster used in this exercise is a DRG digital raster graphic which is a digitized georeferenced version of the USGS topographic maps USGS topos are useful for studying elevation and terrain particularly in non urban areas and for providing a frame of reference for overlaying vector layers or creating new ones however most of the DRGs are
122. llweide in the Filter Box at the top This filters the entire CRS database by name and we ll see the Mollweide World CRS EPSG 54009 appear in the bottom window Select it and hit OK Back on the the Save As menu make sure the Add saved file to map box is checked Browse and save the file in your part 4 folder as couNTRIES_MOL sHP Hit Save then OK Wait a few seconds for the file to be created and added F Donnelly Baruch CUNY 2015 58 CC BY NC ND 4 0 4 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING Z Save vector layer as Z Coordinate Reference System Selector Select the coordinate reference system for the vector file The data points will be transformed from the layer coordinate reference system Format ESRI Shapefile Save as lata part4 countries_mol shp Browse CRS Selected CRS EPSG 54009 World_Mc Filter Mollweide al A Encoding System Z Recently used coordinate reference systems Coordinate Reference System Authority ID _ Save only selected features Skip attribute creation X Add saved file to map Symbology export No symbology z Scale 1 50000 El b Extent current layer a cid Coordinate reference systems of the world Hide deprecated CRSs 5 H Projected Coordinate Systems Mollweide Sphere_Mollweide EPSG 53009 World_Mollweide EPSG 54009 Selected CRS World_Mollweide proj moll
123. lowest to highest Right click on srares_1cc in F Donnelly Baruch CUNY 2015 71 CC BY NC ND 4 0 4 4 4 _ CLASSIFYING AND SYMBOLIZING DATA CHAPTER 4 THEMATIC MAPPING the ML and check the Show feature count option You ll see the number of states in each class varies but the range of values in each class is constant 7 percentage points in each class Layers Ex E Vote X C states loc 51 x 47 8 54 8 5 x 54 8 61 9 16 x 61 9 68 9 21 x 68 9 75 9 9 3 Map data using Quantiles However we could use an alternate classification method called Quantiles Double click on the stares Lcc layer to go back to the Style tab under the Properties menu Change the classification mode to Quantiles and hit Classify Hit OK to re map your data in this scheme and take a look at the result Compared to the equal intervals map quantiles show us a greater range of colors since each class has the same number of features Quantiles divides our data into classes that have an equal number of data points Since we have 51 data points we have about 13 states in each class sorted from low to high as you can see in the feature count Vote Pa states loc 51 x x 62 7 66 8 12 x 66 8 75 9 13 Map data using Natural Breaks We have another option Double click on the states Lcc layer to go back to the Style tab under the Properties menu Change the classification mode to Natural Breaks Jenks and hit Classi
124. m a formula you need to do a copy and paste special and replace the formulas with the actual values that result from the formulas Avoid using any stylistic formating on the data colors underlining or italicizing or the cells borders merged cells If you try to add a workbook to QGIS that has multiple sheets of data it will prompt you to choose a sheet You may want to rename the sheets to clearly identify them rather than using the default Sheeti Sheetz etc The names of attribute columns in shapefiles are limited to 10 characters so if you intend to join a data table to a shapefile keep the column names in the data table short otherwise the names will be truncated and will be difficult to interpret Also when doing the join it s a good idea to remove the custom field name prefix in the joins menu Otherwise the column names will all begin with the name of the worksheet and the actual names of the columns will be truncated and difficult to understand in our example the per_fem column would have become sheeti_per if we hadn t modified the custom field name Column names in a shapefile dbf can t be renamed without the use of 3rd party plugins i e the mmagis tools although you can assign an alias name to describe them under Layer Properties gt Fields tab F Donnelly Baruch CUNY 2015 Al CC BY NC ND 4 0 3 4 PLOTTING COORDINATE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS 3 4 Plotting Coordinate Data In this section you ll lea
125. mately 24 6 and if you scroll to the bottom you ll see the median percentage sort tracts from low to high and select the midpoint where half the values are above and the other half are below this value is also 24 6 For the purpose of our example we ll use 24 6 as our cut off tracts where 18 to 49 year old women make up 24 6 or more of the population will be included while any with less than that number will be excluded Close the stats menu a z A G E Basics statistics A X Input Vector Layer tracts_nyc_data Use only selected features Target field Statistics output Parameter Mean 24 5809149723 L StdDev 5 4742381786 Sum 53193 1 Press Ctrl C to copy results to the clipboard 0 OK Close l J 2 Count stores by neighborhood We should exclude tracts that already have a large number of coffee shops On the menu bar go to Vector gt Analysis Tools gt Points in Polygons Specify TRacts_Nyc_pata as the Input polygon layer and corFEE_sHops as the Input point layer Keep the output count field name as PNTCNT Browse to your part 3 data folder and save the output as TRACTS_DATA_COUNT Make sure the Add result to canvas box is checked Hit OK to create the new shapefile and wait a bit while it does the calculations Close the Point to Polygon menu x Count Points in Polygon Input polygon vector layer tracts_nyc_data v Input point vector layer coffee_shops y Output count field name PNTCNT
126. more oval than sphere like in nature Coordinate System This is the reference grid used for locating places on the earth and measuring distances Latitude and longitude is the most common system but there are other systems with different grid cells and units of measure for example the Universal Transverse Mercator UTM system uses a unique grid Datum When you apply a coordinate system like latitude and longitude to different spheroids or ellipsoids there needs to be a method for creating the grid and attaching it to the earth s surface Mathematically where does one draw the prime meridian and equator on a particular spheroid in order to accurately represent their location The frame of reference for drawing these lines and measuring locations on the surface of the earth is called a datum Collectively when you have these three elements a spheroid or ellipsoid a datum and a coordinate system you have something called a Geographic Coordinate System GCS which uses a three dimensional spherical surface to define locations on the earth The terminology is confusing as a coordinate system is one part of a geographic coordinate system and some systems are named based on the datum they use For example WGS 84 World Geodetic System of 1984 is the most common GCS and uses the WGS 84 spheroid WGS 84 as a datum and latitude and longitude as a coordinate system WGS 84 is used by the Global Positioning System of satellites and thus by individ
127. n or select each map in turn and under Item properties hit the Update preview button 9 Save and export Export your map Print your map out as a PDF or save it as an image Save it in your part 4 data folder as voTERS_2012_LABELS PDF or png Minimize QGIS go to your part 4 data folder and take a look at your final map Voter Partidpation in the 2012 Election ha l Gtizens who Voted ed e 5 e aera z 9 200 400 500 mies Percent Total k i p C 47 8 55 9 ri Source US Coma Surcou Arg ond aer the Section of E 55 9 61 9 MoverBer 2212 odali Tables M 61 9 67 6 Map costed by Prank Dormmly Saud ONG Der 2018 MM 67 6 75 9 4 6 2 Commentary Labeling in QGIS Automatic labeling placement in QGIS and the ability to move labels and customize them has vastly improved in the latest versions of QGIS There are some other options at your disposal e You can also add columns to your attribute table that allow you to specify label details for each feature such as font type size color placement and rotation e The text annotation tool allows you to add call out boxes directly in the map view This is practical if you only need to place a few labels e s You can also use the add label feature within the map composer This can be a little cumbersome since you cannot copy and paste labels but must create each one from scratch ok if you only need to add a few labels
128. n drop down the field you re classifying select the next to last column PerVoteCitz which is the percentage of US Citizens who voted in 2012 Change the number of classes from 5 to 4 Keep the mode as Equal Interval In the Legend Format box add an extra percent symbol to the right of the number 2 so that the symbol is added to the values in the legend below Choose one of the default color ramps for quantitative data with only positive values you should choose a color scheme that uses a single color value from light to dark DO NOT choose a multi color or random scheme Hit the Classify button below the classification window Then hit OK Graduated v Column PerVotCitz E Symbol Change Classes 4 Color ramp WH source v Invert Mode Natural Breaks Jenks v Legend Format 1 2 N Precision 1 Trim Symbol Values Legend x 47 800 55 900 47 8 55 9 x 55 900 61 900 55 9 61 9 x 61 900 67 600 61 9 67 6 x 67 600 75 900 67 6 75 9 Classify Add class Delete Delete all X Link class boundaries Advanced v 2 Examine the Equal Intervals map In the ML expand the menu for strates Lcc to see the classes Equal Intervals is the default classification scheme it took our four classes of data and divided it so that each class has an equal range of values with a min value of 47 8 and a max value of 75 9 our data has a range of 28 1 divide by four and each class covers a range of approximately 7 from
129. national or regional scale According to the Census Bureau The cartographic boundary files are primarily designed for small scale the matic mapping applications at a target scale range of 1 500 000 to 1 20 000 000 The file we re using in this exercise is the most generalized national file available at 1 20 000 000 Boundaries have been generalized to depict land areas to smooth coastlines and borders and to remove small islands This makes the boundaries appear smoother and cleaner at these smaller scales while sacrificing geographic accuracy that wouldn t be visible When choosing vector files for thematic mapping you will need to make sure that the generalization for the file is appropriate for the scale you re working at If you were creating a map of the NYC metro area you would not want to use these boundary files as the generalizations become apparent at this larger scale and will make your maps appear inaccurate You can identify whether a layer is appropriate by looking at the metadata and seeing if an optimal scale is indicated Scale is a proportion of units of measurement on the map versus the actual distance in reality A scale of 1 20 000 000 indicates that one measurement unit on the map represents 20 000 000 units in reality Small scale maps cover large areas while large scale maps cover small areas this may seem counter intuitive but remember that scales represent fractions 1 20 000 is a larger number and thus larger scale than
130. ncy slider to 50 Hit OK Now you can zoom around the map and see some context for the areas selected Note that if you zoom out too far it can take some time for the WMS layer to redraw if you have a slow Internet connection If things are moving too slowly it s best to uncheck the WMS layer to turn it off pan or zoom to your new area of interest then turn it back on Layers Ex cal gt y Ed ES 9 X O subway_stations pt Ae X greenspace tracts_selected x selected_areas x OpenStreetMap WMS x boroughs Browser Layers 3 6 2 Commentary Buffers and Distance Measurement When creating buffers or doing any distance measurements the units you specify must be in the same units as the underlying coordinate reference system Since the coordinate system of our layers is NY State Plane Long Island and it uses feet we have to specify units for measuring the distance of our buffers in feet Whenever you measure distances you should use layers that are either in feet like State Plane projections or meters like UTM zones and not in degrees Coordinate reference systems that are in degrees like NAD 83 the default system used when plotting our coffee shops are difficult for a number of reasons it s much easier for us to conceive how large a kilometer or mile is relative to a degree A thornier issue is that the length of a degree isn t constant the distance between degrees of longitude decreases as we move from the equator
131. nd and water For data representation and analysis you will often need to modify statistical boundaries so that they depict just land areas for example the B_BOUNDARY layer represented the legal boundaries of the boroughs while the Boroucus layer represents just land Layers gt Y O 3 O subway_stations facilities greenspace x boroughs x tracts nyc Browser Layers 10 Modify the tract layer boundaries We ll modify the tract layer to create land based areas that will match the borough layer On the menu bar go to Vector gt Geoprocessing Tools gt Clip Select TrRacts_Nyc as the Input vector layer BorouGHs as the Clip layer and Browse and save the new shapefile in your part 3 data folder as TRACTS_NYC_LAND Make sure the Add result to canvas box is checked Hit OK then be patient while the new layer is created When it s finished close the Clip menu Input vector layer tracts_nyc Use only selected features Clip layer boroughs Use only selected features Output shapefile gt _data part3 tracts_nyc_land shp X Add result to canvas o ok 1 Clean up Select the old tracts_nyc layer in the ML right click and remove it Then drag the new TRACTS_NYC_LAND layer to the bottom of the ML just above the Boroucus layer We now have a new tracts layer that contains just land area and that matches the outline of our boroughs Add some context and check the GREENSPACE and FACILITIES layers to turn them back on
132. nd close the window x T o Y Layer Properties subway_stations Style P X XX General Single Symbol v Unit Millimeter z l y Size 2 00000 Transparency 0 m Labels e ea Rotation 0 009 or A y N Fields Symbols in group Open Library r a Display she gee KO ae O Simple marker t 0 Joins airport arrow capital circle EB Diagrams O N O f Metadata city diamond ellipse pentagon Lale A E Donnelly Baruch CUNY 2015 14 CC BY NC ND 4 0 2 2 ADDING VECTOR DATA E Donnelly Baruch CUNY 2015 CHAPTER 2 EXPLORING THE INTERFACE 7 Change the colors for the parks Double click on the GREENspacE layer in the ML to open the Layer Properties menu for that layer This time we ll choose from a broader color palette Click directly on the color box itself to open the palette options Select the Color Ramp tab Then click around in the palette until you select a shade of green that you like Click OK in the color selector then OK again in and close the menu CA Select color E the style tab to select the color 44 gt gt 4 4h 4h 4h 4D o Le TE O gt gt o y ETI ss Opacity aT 100 HTML notation 2dda89 da O A s YAOI Reset Cancel Change the colors for the facilities and boroughs Make the FaciLiTIES grey or brown and the Boroucus white using the same steps demonstrated above Give the boundaries no
133. nded with the introduction and evolution of GIS The three laws of location science as summarized by Church and Murray Business site selection location analysis and GIS 2009 are e Some locations are better than others for a given purpose e Spatial context can alter site efficiencies the unique circumstances of a given area can alter whether or not a site is optimal e Sites of an optimal multi site pattern must be selected simultaneously rather than independently one at a time if you re planning to open several franchises you should do the planning all at once as each site you open can impact another Its also important to understand the unique spatial patterns of each type of business or industry a phenomena that economic and urban geographers have been studying for many decades Products or services classified as low ordered goods tend to be located in most environments and there will be more of these businesses in places with higher population densities High order goods tend to require a higher population density and will be present in fewer locations For example businesses like gas stations dry cleaners and family doctor s offices will be located in most areas while office towers specialty retail and major hospitals will be located in fewer places spaced further apart Businesses like gas stations and convenience stores tend to cluster around major transportation intersections while car dealerships and hotels tend to cluster
134. ng One 0 oscense e 27 3 1 1 JO II 27 ote ic IEEE 28 Saving Projects and Removing Layers e eee 28 3 2 Geoprocessing Shapefiles ee 28 32 32 33 34 34 3 3 39 AOL DEP sn roos ao eae eeeeyeaeseaeageseeesigs s 36 aa Comments re e o aa a ta ee a 38 38 39 40 41 42 42 342 COMME ss epa riera nara A e a ERA we OBS 44 PERO AAA ir A A 44 Tabular Data Text Files cs ia diras aa eras a ad 45 3 5 Running Statistics and Querying Attributes o e 46 AA ana AAA 46 Oe COMME di a ooo 4 4 A AR AAA A9 eee ee aaa AA AAA AAA 49 Some Basic blood Bes eee eh eee ee eae eee eee ee 49 PEE E E be E E AAA 50 S01 A TEATRE 50 20 2 COMME ss sine Ges aora rada AAA AAA 53 Buffers and Distance Measurement 53 IEEE AAA AR 53 rar ias ara andar AAA AA 54 is WEE 55 EIA III 55 3 2 Commentarios dotados do aa AA AAA es 55 File Management 55 3 8 Considerations and Next Steps ee 56 4 Thematic Mapping 57 4 1 Transforming Map Projections I 57 cepa a ae aaa ee SAA A 57 AV COMME do a Ge See aaron 60 AE IAE 60 Er RARA AAA 61 aran diana rra ia ARA 62 on be eek ard AEREA AA 64 ah Ge ae amp Gp eee E 64 QGIS Projection Handling 2 65 4 2 Transforming Map Projections lll 65 aora reads aaa ana ana 68
135. ngle layers by themselves see example above of air photo flood zones and hazardous sites overlaid Each GIS file is georeferenced meaning that the file is actually tied and related to real locations on the earth If we mouse over Hawaii in GIS software like in the image below we see its longitude and latitude coordinates Just as paper maps were drawn based on map projections and coordinate systems each GIS file has also been created based on a particular projection and coordinate system which means that files that share the same reference systems can be overlaid Since projections and coordinate systems are highly standardized GIS data can easily be shared If two files do not share the same system most GIS software can convert files from one system to another so they ll match This distinguishes map making in GIS versus a graphic design package Maps created in a graphic design package are just simple lines and shapes with no connection to the earth and the components of the map can t be easily replicated to make other maps GIS files used to create maps in a GIS package can readily be shared and used to create any map because they are tied to the earth using standardized systems PE j non aoe e o 157 4919 601 W 21919 17 701 08 GIS files are stored in several formats and each format comes in several different file types Major formats and files include e Raster a continuous surface that is divided into grid cells of e
136. nitially be well placed in the print composer 2 Set the environment for the print layout Hit the New Print Composer to enter the print layout screen and when prompted give the composition a title called First Map On the Composition tab under the Paper and quality menu change the Presets paper size from A4 to ANSI A letter 8 1 2 by 11 The composition tab provides you with options for the map canvas as a whole Once you add individual items a map label legend etc the Item properties tab will become active and if you have the item selected in the canvas you ll be able to edit its attributes Each tab has collapsible menus for editing various elements Y First Map 6 X Composer Edit View Layout Atlas Settings i A FA A A AA F A E BRAR DAGS DAA HPAP LLB aED l 0 50 100 150 200 250 i e EA IATA EPA ATT oe nn nena nene E EnEn Tom Command history n Items x gt J ta em pr E Composition Item properties Atlas generation Y J E a Composition A a w Paper and quality al T E E A IA ls op ANSIA Letter 8 5x11 in Y G 0 gt Width 279 40 iE xz 7 o Height 215 90 E QD Units Number of pages 1 2 in T Orientation Landscape J g pa Page background Change RE Export resolution 300 dpi Y a Print as raster a World file on a a 4 4 gt Guides and Grid 7 x 78 7416 mm y 0 mm page 1 40 9 j 3 Add your map and configure zoom Hit the
137. nnelly Baruch CUNY 2015 89 CC BY NC ND 4 0 5 2 DATA SOURCES CHAPTER 5 GOING FURTHER Canada e GeoGratis http geogratis gc ca geogratis search lang en Canadian government GIS repository provided by the Earth Sciences Sector of Natural Resources Canada e Statistics Canada Maps and Geography http www statcan gc ca eng mgeo geo Boundaries road net works and place name files from Canada s statistical agency United States e TIGER Line Shapefiles U S Census Bureau http www census gov geo maps data data tiger line Extracts of the bureau s TIGER Line files for several legal administrative and statistical areas in the US updated annually e Cartographic Boundary Files U S Census Bureau http ww census gov geo maps data data tiger cart boundary html Generalized extracts of the bureau s TIGER Line files for several administrative areas i e states counties zip codes and census i e tracts block groups metros areas in the US National Historical Geographic Information System http www nhgis org The NHGIS is a project at the University of Minnesota that compiles and provides historical census boundaries and data for the United States from 1790 to 2000 New users must register but there is no cost and downloads are free e Data govs Geodata Catalog http www data gov Data gov s Geodata Catalog a large repository of GIS data from several federal agencies e USGS National Map http viewer
138. nt line or polygon features for a given geographic area and can never consist of multiple types of geometry i e you can t have a shapefile with points and lines Polygon features can be single part where every individual polygon is an individual feature or multi part where multiple polygons can be grouped together as single features Despite it s singular sounding name a shapefile consists of several individual files The following three pieces are mandatory e shp file shape file contains the geometry e shx file shape index file an index of the geometry e dbf file attribute file contains attributes for the features The following pieces are typically ideally included e prj file a plain text file that contains the projection and coordinate system e sbn and sbx files spatial index of the features e shp xml file XML metadata It is important that all of the pieces of the shapefile are kept together in the same folder otherwise the file will not work so be careful when moving files around Renaming files is often problematic if you rename one you must rename all of them with the same name otherwise they won t function together You can easily rename batches of files with the same name but different extensions if you are familiar with using the command line i e Unix Linux shell or DOS Command Prompt it s less tedious than renaming them by hand in a GUI like Windows Explorer F Donnelly Baruch CUNY
139. nt data Chapter 3 Mentioned the Processing Toolbox in the commentary on geoprocessing updated the median income data to the latest American Community Survey 2009 2013 and modified Census commentary about the discontinuation of the 3 year ACS series modified the steps and commentary for joining attribute tables to introduce the ability to modify table prefixes modified screenshots for reprojection of layers to reflect minor changes in the interface changed the WMS example from USGS Topo to OpenStreetMap and mentioned the OpenLayers plugin Chapter 4 Modified the steps and commentary for joining attribute tables to introduce the ability to modify table prefixes and to specify specific columns to include modified screenshots for reprojection of layers to reflect minor changes in the interface re wrote sections on adjusting map scale and adding a scalebar to reflect software improvements Chapter 5 Updated broken links and added some new ones Appendix No changes F Donnelly Baruch CUNY 2015 3 CC BY NC ND 4 0 Chapter 1 An Overview of GIS The goal of this chapter is to provide you with a basic foundation in GIS concepts and software in preparation for the rest of the tutorial 1 1 Basic GIS Concepts Geographic Information Systems GIS are an integrated collection of software and data used to visualize and organize geographic data conduct spatial analysis and create maps and other geospatial information Narrow definiti
140. o consider targeting areas within a 1 3 mile of a subway station that are not located in high income census tracts where women aged 18 49 represent 24 6 or more of the total population and there aren t a large number of existing shops more than 3 F Donnelly Baruch CUNY 2015 51 CC BY NC ND 4 0 3 6 DRAWING BUFFERS AND MAKING SELECTIONS CHAPTER 3 GEOGRAPHIC ANALYSIS Layers as aa O subway_stations _ buffer_subway O coffee_shops facilities greenspace tracts_selected selected areas boroughs XX XX Browser Layers 6 Identify areas Through the selection process the attributes of our previous layers have been preserved in our new layers Select the seLecreo_argas layer in the ML Use the identify button and click on one of the areas You ll see the attributes from our earlier tracts layer While the identifying information is useful many of the other attributes are now incorrect The population figures represent the entire tract and not the small subset we ve selected If we were going to save these layers for future analysis or projects we would want to delete the attributes that are no longer necessary or that are incorrect Save your project 7 Connect to a WMS layer Lets add some context to our abstract selections Zoom in 4 to focus on a small area of the map where there are a number of features in sELECTED_AREAS Tab from the Layers to the Browser menu Select the blue WMS globe in the Browser right cli
141. of shape occurs for larger areas Examples Mercator for the world Lambert Conformal for continents Distance Equidistant maintains accurate distances from the center of the projection along specific lines a straight line on the map will give you the shortest distance between two points the same distance as a great circle on a globe The Geographic Projection also known as Plate Carree or Equirectangular is the most common Direction Azimuthal maintains accurate directions and thus angular relationships from a given central point Azimuthal Equidistant and Gnomic are examples Other projections Interruptions these projections show tears in the earth s surface and try to mitigate them to create something readable Goode s Homolosine is good for showing land areas but poor for showing oceans as these are interrupted Compromises these projections don t preserve any quality of the earth exactly but they compromise to make a map of the earth that looks right Good compromise projections of the earth include Robinson and Winkel Tripel GCS Equirectangular Mercator You can compare maps that use different projections to get a sense for how they distort different areas in particular observe Greenland Common map projections for the world for general reference or thematic use include Robinson Mollweide Goode Homolosine and Winkel Tripel In general projections that appear oval like showing the curvature o
142. one QGIS Browser application If you have a folder with layers and you re not sure what they are you can easily use this application to preview them rather than adding and layering them all in the map interface For details on the stand alone Browser see the Appendix 3 8 Considerations and Next Steps Based on our results in Chapter 3 what would you do next How would you decide where to locate the shop What else would you investigate Is there anything that we ve done in this exercise that you would do differently if you had to conduct an analysis like this for an actual project For more practice some things to try e We counted the number of coffee shops per tract and excluded tracts that have a high number of shops as there would be too much competition Alternatively we could take a distance based approach and exclude any area that s within close proximity to an existing shop Re select tracts using only the demographic data as a criteria Then use the buffer tools to measure areas that are within a 1 5 of a mile of the coffee shops Select the areas of the selected tracts that are within a 1 3 mile of a subway station but are not within 1 5 mile of an existing shop hint look at some of the geoprocessing tools to accomplish this e Shrink the selection areas by removing the greenspace and facilities from the final areas rather than simply overlaying them on the selection areas e Try looking at how well each subway station
143. ons of GIS focus on the software and data while broader definitions include hardware where the data and software is stored metadata data that describes the data and the people who are part of the system and interact with it as creators curators and users Another definition GIS is a visual system that organizes information around the concepts of place and location that can be used for geographic analysis map making database management and geospatial statistics GIS can be applied to virtually any discipline or endeavor Ci fl ik Be jam EGO ee RU EO eee BPok aoa ta is ES alar of aft z a r glir A AATE Maa A Pi In a GIS geographic features are represented as individual files or layers that can be added to a project These features are not maps in and of themselves but are the raw materials used for map making and analysis For much of the 20th century cartographers drew geographic features on individual mylar or acetate sheets and layered those 1 1 BASIC GIS CONCEPTS CHAPTER 1 AN OVERVIEW OF GIS sheets over a paper base map to create maps GIS uses the same principles of layering with individual files consisting of features that can be layered on top of each other in GIS software GIS software acts as an interface or window for viewing and manipulating GIS data The ability to add different layers is quite powerful as combining the layers allows for analysis that would be impossible if you were viewing si
144. osoft has ceased supporting the DBF format DPF files are VERY particular names for columns must be kept short less than 10 characters should contain no spaces or punctuation except underscores and cannot begin with numbers Unlike plain text files columns in a DBF table have a specific data type associated with them text integers real numbers etc In order for joins between DBF files and shapefiles to work the ID fields must be in the same format text or numbers IDs should normally be stored as text You can open and edit DBF files that are associated with shapefiles However you should NEVER EVER re sort the data in a DBF file that is associated with a shapefile if you do the data will become misaligned with the features in the shapefile and will no longer match You also CANNOT add new rows to the DBF since there will be no geometry in the shapefile to match it You can edit existing values add new columns and delete columns as long as you don t delete the ID fields at the beginning of the sheet If you need to do substantial editing of a stand alone DBF file that is NOT part of a shapefile it is best to copy all of the data in the DBF and paste it into a new blank workbook and save it in a spreadsheet format For example if you want to create a calculated field with percent change or do ANY work that involves formulas create a new blank workbook DO NOT work in the DBF file and do not create a second worksheet within
145. ox browser formerly the proprietary Netscape and F Donnelly Baruch CUNY 2015 9 CC BY NC ND 4 0 1 3 OPEN SOURCE CHAPTER 1 AN OVERVIEW OF GIS LibreOffice formerly the proprietary Star Office and a branch of OpenOffice are examples of the latter Why would people want to bother with creating FOSS software e It gives programmers a chance to practice their skills It gives programmers a way to enhance their prestige for their craft as they can become known in different programming circles e Open source is an ethos for some who believe that software and information should be free e Some see it as a superior model since the code is open there is a better chance that improvements can be made more quickly and that bugs can be discovered more easily than in proprietary software as open source harnesses the power of the masses e Businesses may prefer it because it does not tie them to costly proprietary software that may go out of date or out of business with open source there is always someone who can take over a project and keep it going since the code is free and transparent e If proprietary software for a certain application is inefficient insufficient expensive or non existent FOSS software can be created to meet the need The number of FOSS GIS packages has grown over the course of the last decade and the Open Source Geospa tial Foundation OSGEO was created to support the collaborative development of the software an
146. p a_metro_counties e Web Services in addition to accessing files locally GIS can tap into files stored on the web that are published using a variety of services Instead of downloading users can connect to web based layers and render them directly in GIS Layers are rendered using Web Mapping Services WMS which renders layers as rasters and as Web Feature Services WFS which renders layers as vectors and allows for the display and manipulation of attributes WMS is more common and is particularly useful for providing base map features Raster and vector GIS files exist spatially in that you can see the grid or shapes and their corresponding location on the earth Vectors also have a tabular component that is particularly valuable For example every feature in a vector file showing state boundaries has an associated record that s attached to it and stored in a table for those states This attribute table contains columns or fields that store values for each state such as the state s name values like population or area that describe it and ID codes that uniquely identify each one The names can be used by the GIS to label each state and the values like population can be thematically mapped E Attributes of admin x F LE LE LE E lala Penne yteanie Show al Selected Records 1 cut of 2585 Record 14 lf 2387 v EN The ID codes for each state can be used to join the attribute table fo
147. pen it in Adobe or your PDF viewing software Double click on your PNG file to open it in your default image viewing program or open it with your web browser Congratulations on creating a finished map 4 5 2 Commentary QGIS Map Composer Scale Bars and Other Details In some GIS software packages the current view in the map window and the print layout are dynamically linked and a change in one such as adjusting the zoom affects the other This isn t the case with QGIS the two are separate If you do change something in the map view such as reclassifying the data you can update the map composer under the item properties tab for the map by hitting the Update Preview button Changes in focus or zoom between the view and the composer are not connected at all which relieves a lot of potential headaches The print composer allows you to customize minute details of the canvas map and legend more so than other open source packages The composer also gives you the ability to draw shapes or Y add portions of an attribute table directly to a map You can also store more than one map in a single project From the map view you can use the print new button to create new individual maps and the Y print composer button to manage your maps and choose a particular one to show or edit The scale bar feature was updated in QGIS version 2 8 and is much easier to use than it previously was You can still take a manual approach if you wan
148. puter amp OS C is TT gt File name subway_stations shp b_boundary shp v ESRI Shapefiles shp SHP v 3 Do your layers look jagged If not skip this step If so on the Menu Bar select Settings gt Options gt Rendering and under Rendering Quality check the box that says Make lines appear less jagged at the expense of some drawing performance and hit OK 4 Experiment with changing the drawing order Click on the first layer that s listed in the Map Legend ML hold down the left mouse button and drag it to the bottom of the list This moves that layer from the top of the drawing order to the bottom layers in the Map Legend ML are stacked on top of each other and their order in the list determines which are visible relative to others Move the Boroucus layer to the top of the list to see what happens 5 Order the layers Drag the layers in the Map Legend ML so they appear in this order from top to bottom SUBWAY_STATIONS GREENSPACE parks and wildlife areas FACILITIES airports ports prisons BOROUGHS B_BOUNDARY borough legal boundaries 6 Change the color for the subway stations Double click on the susway_stations layer in the ML to open the Layer Properties menu for that layer Click on the Style tab Click the drop down menu beside the Color box Change the color to blue by choosing from the palette of standard colors Click OK on the Style menu to make the change a
149. qual size Each cell appears as a particular color based on some value i e reflected light Files in the raster format are similar to digital photos Common raster objects include air photos satellite imagery and paper maps that have been scanned Raster files can also consist of photos or imagery that have been generalized or have had value added to them to create a new layer like a land use and land cover layer or a grid showing temperature There are many different file formats some common ones include Tiffs tif JPEGs jpg and SID sid Unlike regular tif or jpg files GIS raster files are georeferenced E Donnelly Baruch CUNY 2015 5 CC BY NC ND 4 0 1 1 BASIC GIS CONCEPTS CHAPTER 1 AN OVERVIEW OF GIS e Vector discrete coordinates and surfaces that are represented as individual points lines or polygons areas Vector files appear to be more map like and are always abstractions rather than actual images i e shapes to represent boundaries points to represent cities Common file formats include ESRI shapefiles shp ESRI coverages cov Google KML files kml and Geographic Markup Language files GML e Tables data tables that contain records for places can be converted to GIS files and mapped in several ways If the data contains coordinates like longitude and latitude the data can be plotted and converted to a vector file If each data record contains unique ID codes for each place those records can b
150. r and vector data formats are cross platform and can be used in any GIS software package E Donnelly Baruch CUNY 2015 10 CC BY NC ND 4 0 Chapter 2 Exploring the Interface The goal of this chapter is to familiarize you with the interface and basic features of GIS in general and QGIS in particular You ll also add and configure some layers that you ll use later in Chapter 3 2 1 The QGIS Interface This section will introduce you to the QGIS interface you will configure the interface in preparation for the rest of this tutorial 2 1 1 1 Steps Launch QGIS Desktop If you re using Microsoft Windows look under the Start Menu gt All Programs gt QGIS Wien gt QGIS Desktop Configure plugins Were going to turn off the plugins that we re not going to use to keep our interface uncluttered Go to Plugins gt Manage and Install Plugins Click on the Installed Plugins button in the menu on the left Keep the following plugins checked DB Manager fTools GdalTools and Processing Uncheck all of the other tools to turn them off Note there may be a slight pause or delay when you select a plugin to uncheck it so be patient Hit the Close button when you re finished Configure the toolbars Likewise we re going to turn off toolbars that we won t need Right click on a blank area of the toolbar to get the toolbar view menu Make sure the following ten features are checked Browser Layers Attributes Database Digi
151. r the GIS file to a tabular file that contains state level data For example a GIS file of state boundaries with a state code can be joined within GIS using relational database techniques to a text or spreadsheet file that has state level data and that uses the same codes to identify each state The data in the table which was just a regular table with no geospatial geometry can now be visualized and mapped in GIS There are number of standard ID codes that can be used for joining data The two most common families of codes are ANSI FIPS created by the US government to identify every single geographic entity in the US there are also FIPS codes for countries and ISO created by the International Standards Organization to identify countries and their subdivisions F Donnelly Baruch CUNY 2015 7 CC BY NC ND 4 0 1 2 GIS SOFTWARE CHAPTER 1 AN OVERVIEW OF GIS Attribute table tl_2012 us state 0 56 feature s selected STATENS GEOID STUSPS NAME 01 01779775 01 AL Alabama 1 02 01785533 02 AK Alaska 2 O4 01779777 04 AZ Arizona 3 05 00068085 05 AR Arkansas g Attribute table tinal_cemograpnic 0 51 feature s selected SUMLEVEL GEO NAME TOTPOP TOTPOP_ME o 01 040 Alabama 4633360 NULL 1 02 040 Alaska 683142 NULL 2 040 Arizona 6324865 NULL 3 05 040 Arkansas 2838143 NULL 1 2 GIS Software A standard interface for GIS software has evolved over time Typically GIS software has a da
152. rams you simply have to go to File gt Save As and under the Save as type drop down menu choose Excel 97 2003 Workbook Some important rules to follow to insure that your data will load properly in QGIS Your spreadsheet should consist strictly of rows of data with columns of attributes that describe them you should not have titles footnotes sum totals or any stray text or information It must be a strict grid of data The first row will be your header row with the names of the columns you cannot have multiple header rows Names for columns should be kept short less than 10 characters should contain no spaces or punctuation except underscores and should not begin with numbers In order to preserve the formatting of the data you should specify formats for each column text numbers date etc Remember that the data type of the unique ID column in your spreadsheet must match the data type of the unique ID in your spatial file If one is saved as text and the other is a number the join will fail You should never mix text and numeric data in the same column Columns should be either text or numbers If you mix text like footnotes into your numeric columns then the entire column will be saved as text and you won t be able to treat the numbers as numbers i e for classifying data performing calculations etc in QGIS Do not embed formulas in your data QGIS won t know how to interpret them If you have data that was created fro
153. rn how to take a text file with coordinate data plot the data in GIS and convert it to a shapefile It s often difficult to find pre existing shapefiles of buildings particularly businesses and residences But you can create your own point layers if you have the coordinates of the places you wish to plot In this exercise you ll create a layer of coffee shops from a text file that lists each store with its longitude and latitude coordinates Since these coordinates don t match the state plane system coordinates of our existing layers we ll have to plot them first and transform them to our system The coordinate data for the coffee shops was downloaded from a database called ReferenceUSA and processed so that it was ready for plotting Please note that this data is from December 2012 and is used as a teaching example it should not be used for any commercial purpose 3 4 1 Steps 1 Inspect the text file Go to your data folder for part 3 open the file nYc_coFFEE TXT in a text editor like Notepad on MS Windows and examine it This is a tab delimited text file with data for coffee shops in NYC each record represents one store and each attribute column is separated by a tab Close the file when you re finished 2 Launch a blank project We don t want to plot our longitude and latitude based points over top of our NY state plane layers as they don t share the same coordinate system We ll use a blank workspace to plot our layers and then we l
154. ruch CUNY 2015 39 CC BY NC ND 4 0 3 3 JOINING AND MAPPING ATTRIBUTE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS York State for New York County and the last six 000201 are for the census tract number the last two digits of the tract number are reserved for numbers to the right of a decimal point In an attribute table these codes may appear in separate columns state county tract or in a single column as one string A list of US ANSI FIPS codes for states and territories is available in the appendix of this tutorial and the US Census Bureau maintains lists of codes on its website http www census gov geo reference ansi html The US government has also created two letter alpha FIPS codes for each of the world s countries and uses them for international data published by various agencies However international data is more commonly coded with ISO codes ISO 3166 which are available in a two letter alpha format a three letter alpha format and a three digit numeric format Sample Country Codes Country FIPS 10 ISO 3166 Denmark DA DK DNK 208 Djibouti DJ DJ DJI 262 Dominica DO DM DMA 212 Dominican Republic DR DO DOM 24 It is generally best practice to store ID codes as text and not as numbers since they don t represent quantities Storing ID codes as numbers can result in data loss and misidentification If codes begin with a value of zero and the ID is stored as a number the zero will be dropped and the code will be incorrect Ex
155. s a map or chart in a jpg or basic image file that lacks coordinates and transform it into a GIS layer Plugins Many developers have taken advantage of QGIS extensible architecture to build plugins that offer a variety of additional features Plugins are available under Plugins gt Manage and Install Plugins and include officially supported QGIS modules as well as third party plugins Need more analytical capabilities There are a number of other analysis tools that are available under the ftools menu and via plugins You can also try the QGIS GRASS plugin and learn how to use GRASS GIS software Geodatabases like PostGIS and Spatialite also give you the capability to perform spatial queries and geoprocessing operations and scripting langauges like Python allow you to customize and automate tasks F Donnelly Baruch CUNY 2015 91 CC BY NC ND 4 0 5 3 ADDITIONAL CONCEPTS AND APPLICATIONS CHAPTER 5 GOING FURTHER The QGIS website and the OSGeo foundation have links to additional manuals and tutorials for learning QGIS http www osgeo org educational_content Harvard has a concise and graphics rich QGIS tutorial at and the QGIS QGIS Tutorials blog not affiliated with the QGIS project has detailed tutorials for individual tasks at http www qgistutorials com en QGIS Uncovered is an exten sive collection of video tutorials search for it on YouTube In print Learning QGIS 2 0 by Anita Graser provides a good introduction with
156. s gt Polygon Centroids Symbols are used to show qualitative data name or feature type or quantitative data proportions or numbers and are often divided into four types Nominal qualitative measurements like the name or type of feature shown using unique symbols Ordinal quantitative measurements with a general order of size like small medium or large shown using symbols of different sizes or colors Interval quantitative measurements with a specific beginning point and range of specific values distance temper ature elevation shown using a variety of symbols isolines shaded areas graduated symbols Ratio a type of interval measurement that shows the relationship between the area and some phenomena time to cover a distance population density Symbols are often designed to mimic the features they represent i e airplanes for airports little buildings with flags to represent schools etc these are all examples of nominal symbols In some cases features may be represented with geometric shapes circles squares triangles that can be easily distinguished on small scale maps Some features may be represented using a standard convention for classifying them i e mining maps may label minerals based on their abbreviation in the periodic table Sn for tin Pb for lead Cu for copper etc A single symbol can be used to identify a feature Varying the size or color of the symbol can indicate quantity The width and
157. s and touches to refine the selection However several other spatial query options exist in other GIS packages such as selecting features that border each other or that are within or have their center within other features the latter would have been the preferred option for selecting tracts within NYC boroughs QGIS does have a Spatial Query plugin that can be activated in the plugins menu and provides additional selection options However the tool seems to have trouble when making selections between two polygon layers which is why it wasn t demonstrated in this tutorial although it works better when selecting points or lines in relation to polygons It isn t clear if this is a shortcoming with the tool or with shapefiles that aren t perfectly formed If you need additional spatial query options you could also use a geodatabase PostGIS or SpatiaLite to do spatial selections Its pretty common that you ll download geographic data that covers an area that is wider than you need Since GIS data is malleable it usually makes sense to grab data for a larger area and select out just the portions you need if you can t find a layer that consists just of the areas you want This is something to keep in mind when you search for data on the web Geoprocessing Its also rather common that you ll download shapefiles that represent boundaries but these boundaries will often incorporate land and water If your intention is to show the actual bound
158. s one by one or by hitting the dropdown beside the ES select feature button and choosing one of several options Layers 8 x 2 Y aae X O subway stations x greenspace g Attribute table subway_stations Features y 16 BERS HP AE Ej _ stop_id stop_name trains complex_id 250 ESG 125 St 1 mn010 al h 4 Show Selected Features 6 Select Features by Attribute Close the attribute table for the susway_stations Hit the Select features using an expression button on the tool bar This opens the Select by expression window which allows you to select features based on shared attributes In the Function list scroll down to Fields and Values and hit the plus symbol to expand the options Double click the bcode field which adds it to the SQL Clause box at the bottom Click on the equals sign in the Operators section Hit the All unique button under the Field values box to display all possible values for the bcode field Double click on the 36005 value listed in the value field Your statement in the SQL Clause box should read bcode 36005 Click the Select button You ve just selected all of the subway stations that are located in the Bronx 36 is the census code for NY State 005 is the code for Bronx County Note the expression window is also available in the attribute table window via the same button f Z Select by expres
159. s tutorial we will be using QGIS which is free open source software FOSS Open source software is an alternative to proprietary software e Open source software is free you don t have to purchase it and you can freely distribute it to anyone else as opposed to proprietary software which you must purchase and typically can not share with anyone since it s copyrighted e The source code or actual computer programming that was used to create the software is transparent as opposed to proprietary software where the code is hidden and encrypted e Under the open source model the programming code is transparent and you are free to change and make improvements to it this is strictly prohibited with proprietary software Open source software can be created in several ways A programmer or developer creates software from scratch because they have some need that isn t being met by current software Over time as other programmers discover the project they may choose to contribute to building or improving this software and they rally around the creator and begin to form a group that becomes devoted to the project The Linux operating system and the Perl program ming languages essentially began this way Alternatively a group of people who receive support from a business or entrepreneurs take software that was formerly proprietary but is no longer commercially viable and they build on this product and re release it as open source The Mozilla Firef
160. s will run into problems later on when trying to manipulate the GIS files You should always be sure to specify the projection properly and make sure that all files share the same one most GIS software will give you the ability to re project data E Donnelly Baruch CUNY 2015 8 CC BY NC ND 4 0 1 3 OPEN SOURCE CHAPTER 1 AN OVERVIEW OF GIS GIS software provides users with a variety of ways for querying geographic data either by selecting records in the attribute table or shapes in the view or by conducting searches where you build queries to high light features that contain specific attributes or that have some relationship with another geographic layer GIS software comes with a variety of editing tools that allow you to modify the geometry of GIS files For example you can merge features together break them apart or clip out or select certain areas to create new files Collectively these processes are known as geoprocessing You geoprocess layers in order to prepare raw data for analysis to create new layers or data or to simplify layers for cartographic or aesthetic purposes GIS also provides the ability to edit files on a feature by feature basis Most GIS programs have a separate map layout or print layout where the user can create finished maps with standard map elements like titles legends scale bars north arrows and accompanying text Finished maps can be exported out of the GIS as static files such as pdfs or jpgs Users
161. scure patterns illogical scheme for dividing data Violation of basic cartographic convention improper conventions for labels and color e Poor figure ground relationship inability to clearly distinguish land from water or foreground from background e Poor color scheme random schemes for quantitative data color that s improper for final format color print photocopy screen projection etc e Information overload too much information several variables or map elements or noise unnecessary infor mation Chartjunk concept defined by the graphic designer Edward Tufte refers to kitschy or gimmicky elements that add nothing to the message of a map or graphic e Factual errors mistakes with labels data or geography Violates expectation of the user simplification or generalization is too much for the user to accept e Offends culture of the user the message or how the message is communicated text colors violates taboos that a user or group cannot accept F Donnelly Baruch CUNY 2015 80 CC BY NC ND 4 0 4 6 ADDING LABELS CHAPTER 4 THEMATIC MAPPING Output Formats PDFs are a good format for creating stand alone documents PDFs are a vector based file meaning that the geometry of every shape point lines and polygons is stored as a series of coordinates If you re working with vector features to begin with the output in the PDF should be fairly smooth and if you zoom in to the document you should see all of th
162. selections difference between data formats organizing projects and data Chapter 3 GIS Analysis using site selection example in NYC basic geoprocessing tasks attribute table joins plotting coordinate data buffers basic statistics advanced selection web mapping services Chapter 4 Thematic mapping using countries and US states as an example map projections coordinate systems data classification symbolization labeling map layouts Chapter 5 Going Further with GIS exploring and evaluating online sources for free data exploring open source and ArcGIS software resources for learning more Organization of this Tutorial This document is divided into five chapters and subdivided into sections for specific tasks Each section begins with steps for learning a specific application or process the what and when followed by commentary that explains various facets of the process the how and why The process and the commentary were separated in order to keep the steps as concise and easy to follow as possible with few digressions you follow the steps first and then go back and understand the details of why you followed the steps you did This tutorial and associated screenshots were created using QGIS in a Windows 7 operating system The names of certain tools and menus may vary slightly between operating systems but functionality should be the same The following conventions are used throughout Each section begins with steps for
163. sense to map values as whole numbers cities by number of crimes states by total population counties by number of renter occupied housing units etc But in each of these examples a particular place could have a higher value simply because it has more people or is a larger place In order to make more meaningful comparisons it s often necessary to do a little math Percentage value of subset total value 100 3 000 renter units 10 000 renter units 100 30 units are rentals Rate value total value multiplier 400 robberies 50 000 people 100 000 people 800 robberies per 100 000 people Ratio value 1 value 2 4000 cars 3000 people 1 33 cars per person Density value land area 800 000 people 2500 sq miles 320 people per sq mile Percent Change recent value older value 1 100 10 000 people 9 000 people 1 100 11 1 change 4 4 Classifying and Symbolizing Data In this section you ll learn about the different methods for classifying data and the best approach for choosing color schemes to symbolize your data These are important concepts to grasp as they have a direct impact on how successful your map will be in communicating your data 4 4 1 Steps 1 Classify your data Select strates Lcc in the ML and double click to open the Properties menu Go to the Style tab In the classification drop down at the top of the menu switch the option from Single Symbol to Graduated In the Colum
164. ses you should consider the number of data points the range of the data the purpose of the map and the color choice based on the output While a certain number and range of colors may look good on a color printed map they may appear washed out if the map is shown on a projector or blurred together if photocopied in black and white You should design with the final output in mind After ranking the data from lowest to highest values there are a number of classification methods Equal Interval each class has the same range of data values Easily understood by map readers but does not account for data distribution and can result in categories with few or even no values Quantiles each class has the same number of data points Always produces distinct map patterns but can often create categories that have an inconsistent range of values Natural Breaks classes are created based on the location of gaps in the data Since the data is divided based on its distribution it is good for distinguishing patterns but like the Equal Intervals method it is sensitive to outliers Unique Manual classes created based on some external criteria Should only be used when justified otherwise the classification is completely arbitrary Its often necessary to make some common sense adjustments to any classification scheme such as creating unique classes for values of zero or missing values and adjusting classes so they don t contain a mix of negative and
165. sion subway_stations P Function list Selected function help Search Field al Fields and Values Double click to add field name to stop_id expression string stop_name trains complex_id multi_st bcode stop_lat stop_lon Anas 3 Recent Selection Load values all unique 10 samples w Operators A JIL JG Expression bcode 36005 IHA a0 Es Select Close Output preview J E Donnelly Baruch CUNY 2015 20 CC BY NC ND 4 0 2 4 EXPLORING FEATURES CHAPTER 2 EXPLORING THE INTERFACE 7 Clear selected features Click the deselect features button on the toolbar to remove selected features from all layers Alternatively with the 3 Select features button active you could click on an area of the map that has no stations to clear the features or you could clear the current selection from the attribute table 8 Labeling features Attributes stored in the table can also be used to label features Select the SUBWAY_STATIONS layer in the ML to activate it Click the layer labeling options button on the toolbar alternatively you can double click on the layer in the ML and access the Label tab via the layer properties menu Check the box that says Label this layer with and in the dropdown choose the trains column Click OK Explore the map a little and notice how the labels shift as you zoom in We ll experiment more with labeling later on Click the labels but
166. ss at its widest point to make sure we have the math right Most continental and global projections are in meters and degrees Converting degrees to other units of mea surement particularly at this scale is complicated and should be avoided Use a projection in meters and convert to kilometers or miles For regional and local projections like UTM and State Plane US mappers will have an option between meters or feet F Donnelly Baruch CUNY 2015 79 CC BY NC ND 4 0 4 5 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING In our map we created a scale bar that s just for the US conventional practice would require us to create separate bars for Alaska and Hawaii since they are not at the same scale On the other hand scale bars and north arrows are only crucial on reference maps street maps property maps topographic maps etc where the emphasis is on depicting direction or distance for many thematic maps they can be considered optional We could have omitted them from our map General Map Design When creating maps you need to design with the end use format and audience in mind If you re designing a map that you re going to embed as an image in a document or web page you should change the size of the canvas and design the map to the specifications for the document Creating a full size 8 1 2 by 1 map and scaling or cropping the final image is a bad idea you ll introduce distortion into the map and text will become illegible You also need
167. t 3 geography totpop fem18_49 per_fem medinc moe_medinc PNTCNT El Recent Selection a gt Output preview J This will select all census tracts where the percentage of the population who are women aged 18 to 49 is greater than or equal to 24 6 the median income is less than 100k and there are currently less than 3 coffee shops Close the menu and view your selections in the map view 6 Save your selection as a new shapefile Select TRACTS_DATA_ COUNT in the ML Right click and choose Save As Make sure to check the two boxes that say Save only selected features and Add saved file to map Browse to your part 3 folder and save the selection as TRACTS SELECTED Hit OK to save it Select the old TRACTS_DATA_COUNT in the ML right click and remove it Drag the new TRACTS_ SELECTED layer to the bottom of the ML just above the BOROUGHS layer Check the BoroucHs to turn them on and uncheck the corFEE sHops to turn them off Save your project E Donnelly Baruch CUNY 2015 48 CC BY NC ND 4 0 3 5 RUNNING STATISTICS AND QUERYING ATTRIBUTES CHAPTER 3 GEOGRAPHIC ANALYSIS a Lo DA g Save vector layer as E Format ESRI Shapefile v Save as ta part3 tracts_selected shp Browse CRS Layer CRS y New York Long Island ftUS Change Encoding System Sl a x Save only selected features Skip attribute creation X Add saved file to map Symbology export No symbology Z Scale 1 50000 b Extent curren
168. t Options gt CRS Tab and you can disable on the fly reprojection completely This menu will also allow you to change the default CRS from WGS 84 if you know you ll regularly use some other system Also you need to remember that if you have added files to the map window removed them and then added new files that don t share the same CRS as the original ones you need to reset the CRS of the map window by selecting a layer in the ML right clicking and choosing the option to Set Project CRS From Layer Z Options CRS x Ne General w Default CRS for new projects System Don t enable on the fly reprojection 5 Data Sources O Automatically enable on the fly reprojection if layers have different CRS Enable on the fly reprojection by default Always start new projects with this CRS Rendering tw Colors EPSG 4326 WGS 84 Select Canvas Legend CE Map Tools When a new layer is created or when a layer is loaded that has no CRS E Composer Prompt for CRS IE Digitizing Use project CRS Use default CRS displayed below w CRS for new layers 4 GDAL EPSG 4326 WGS 84 Select Locale V Default datum transformations stim trancfarmatian ssl n oF Network 4 2 Transforming Map Projections II Now that you ve had some practice in working with coordinate systems and map projections we ll prepare the file for our US voting map by converting it from its default GCS
169. t layer g OK Cancel Help 3 5 2 Commentary Selection Criteria Since the goal of our exercise is to demonstrate the capabilities and possible uses of GIS we re not adhering to strict criteria in our site selection process the example is merely illustrative Is a cut off of 24 6 of the population for women aged 18 49 reasonable It really depends on your goals and whether you would prefer to have a focused narrow selection of places or a more expansive one Does it make sense to omit a tract that is only a tenth of a decimal place below 24 6 These are the kinds of decisions you ll have to make for each project you do You may decide that a line has to be drawn somewhere and that s it or you may wish to allow an exception within a few decimal places or to round your numbers You also could decide to make a qualitative decision based on what you know about the neighborhood that s near the dividing line should you include it or exclude it You have a few tools at your disposal for making these decisions the basic statistics for determining mean median range and standard deviation to establish a baseline are helpful The data classification tools for symbolizing your data based on quantiles or equal intervals can also aid your decision we ll discuss these later on QGIS also has a number of 3rd party plugins you can explore for additional statistical tools Regardless of what you do look at the attribute table and mak
170. t more control over the scale bar s configuration by selecting the Map Units option under the Scalebar s units menu The North America Lambert Conformal Conic projection is in meters so by default the map units in the scale bar are in meters In most cases you will have to convert measurements to larger units that make better sense To do this decide how many units you want an individual box in the scale bar to represent and then do the conversion A simple example if we want the individual segments of the scale bar to represent 300 km we would enter 1000 in the the Map Units Per Bar as 1000 meters 1 km and then multiply the conversion factor by the segments we want 300 1000 300 000 and enter the result in the Segment Size Box To make sure we did the math correctly compare one segment of the scale bar to the length of a known feature on the map For example Colorado is just over 600 km in width so you can hover the scale bar over the state to see if it s approximately correct Using kilometers on a map of the US would be heretical so we need to use a different conversion factor If we want the individual segments of the scale bar to represent 200 miles we would enter 1609 as the the Map Units Per Bar as 1609 meters 1 mile and then multiply the conversion factor by the segments we want 200 1609 321 800 and enter the result in the Segment Size Box We can compare our scale bar to Illinois which is just over 200 miles acro
171. t the original 6z_2010_us 040_00_20M file in the ML right click and remove it Then select the new states layer in the ML right click and choose Set Project CRS from Layer This renders our states file correctly and changes the window to EPSG 102009 Save your project Layers Ex F aal aa 5 Coordinate 1583571 1873178 Scale 1 87 180 279 y X Render EPSG 102009 IGT A Browser Layers Current CRS North_America_Lambert 5 Inspect the layer Zoom in to the northeastern US to the area around New York City You ll notice that unlike the previous census file we worked with from TIGER this file has already been modified to remove bodies of water from state boundaries But if you look at the NYC area you ll see that Manhattan and Long Island appear joined to the mainland This shapefile is from the Census Cartographic Boundary Files they are TIGER files that have had their boundaries simplified so they appear less jagged at small scales viewing the US as a whole but are not appropriate for large scale maps viewing a small area like the NYC metro amp Zoom back out F Donnelly Baruch CUNY 2015 67 CC BY NC ND 4 0 4 3 MORE GEOPROCESSING AND JOINING CHAPTER 4 THEMATIC MAPPING Generalization and Scale The Census Cartographic Boundary Files http www census gov geo maps data data tiger cart boundary that we are using in this part of the tutorial were designed for creating maps of the US at a
172. ta view that consists of a table of contents that lists files that have been added to a project a data window that displays the GIS files and a set of toolbars and menus for accessing various tools and launching various processes Dragging the layers in the table of contents changes their drawing order and right or left clicking on a layer in the table of contents will reveal individual properties for that particular layer You can also access the attribute table of the layer and a symbol tab for changing how the features are depicted or classified There are several tools for zooming in and out to examine different layers and to change the extent of the view Qaantun GE 10 8 gare Me EH Yen Lar pr Pan ai Hebe a dd oed aa Pe e e 4 ata deed oo EERTE Ai uA OD jme h E capear h b L a al Cale Pe a F amp 14317 3 G0 EEF 6 di enir i The way that coordinate systems and projections are handled is different for individual GIS software packages In general the options are define the projection and coordinate system for the project before adding the files or the project automatically takes the projection of the first file added If you try to add GIS files that have different projections some software may try to re project the data on the fly while others will simply fail to draw the new layers Even if the software can correctly draw a layer without the user defining it or even if it can re project layers on the fly user
173. table for the layer 94 A 1 STEPS APPENDIX A QGIS DESKTOP BROWSER P QGIS Browser Ao Refresh Ea Manage WMS New Shapefile D Set layer CRS 4 gis_prac_data a Param Metadata Preview Attributes 4 5 part2 2 b_boundary shp 2 boroughs shp drg_central_park tif drg_trees tif O facilities shp 2 greenspace shp 2 subway_stations shp part3 2 buffer_subway shp C3 coffee_shops shp gt nyc_coffee txt C selected_areas shp C t1_2012_36_tract_nys C tracts_data_count shp CA tracts_nyc shp C tracts_nyc_data shp 5 Experiment with viewing other files Select some of the other layers to preview them The attributes of tabular files like DBF or CSV can be previewed but there is no geometry to display Clicking on a folder in the browser will display the full contents of the folder When you re finished exploring close the browser E Donnelly Baruch CUNY 2015 95 CC BY NC ND 4 0 Appendix B Tabular Data DBF Files We ve covered Excel xls and delimited text txt or csv in this tutorial as two of the three stand alone data table formats you can use in QGIS The third format which we did not cover are DBFs dbf DBF files are an old data table format from a database system called dBase While dBase is no longer common the file format has survived in part because DBFs are an integral component of shapefiles that store all of the attributes of
174. te Reference System Authority ID Geographic Coordin EPSG 4269 NAD83 CSRS EPSG 4617 NAD83 CSRS98 EPSG 4140 proj longlat ellps GRS80 towgs84 0 0 0 0 0 0 0 no_defs cra 5 Convert the plot to a shapefile Even though the points have been plotted it isn t a shapefile yet we have to convert it When we convert it we can also transform it to match our other layers To convert it select and right click on Nyc_coFFEE TxT in the ML and choose Save As This time hit the little globe button beside the Selected CRS In the coordinate system menu under recently used coordinate systems select the New York Long Island projection and hit OK if you don t see it there use the filter to search for it and select it Save it as an ESRI shapefile in your part 3 data folder and call it corrEE_sHops Make sure the Add saved file to map box is checked Then hit OK to save the layer XK Save vector layer as p Format ESRI Shapefile Save as 3_prac_data part3 coffee_shops shp Browse CRS Selected CRS EPSG 2263 NAD83 New York y Encoding System v Save only selected features Skip attribute creation X Add saved file to map Symbology export No symbology y Scale E E Donnelly Baruch CUNY 2015 43 CC BY NC ND 4 0 3 4 PLOTTING COORDINATE DATA CHAPTER 3 GEOGRAPHIC ANALYSIS 6 Re open our project and add the new layer The new corFEE_sHops layer has been added to
175. th raster data GDAL OGR command line tools for converting files and projections and for basic queries Python for data processing and creating customized tools and a geodatabase application PostGIS for server based databases and Spatialite SQLite for desktop use Individual FOSS software will often contain a large group of core components as well as a number of plug ins that were subsequently designed to add new functionality Plug ins may be created by the developers or by third parties and over time can be incorporated as core functions in later versions of the software ArcGIS created by a company called ESRI has been on the market for several decades and is the dominant proprietary non FOSS GIS software on the market It s used by most government agencies and universities Since it is rather expensive to purchase for individual use you tend to see it more often in institutional settings If you are affiliated with a college or university chances are you ll be able to access it somewhere on your campus ESRI does distribute trial versions of the software for education and home use A rival product MapINFO created by Pitney Bowes has a smaller but equally dedicated following If you find that you need to learn one of these products making the transition from FOSS is relatively straight forward as most GIS software operate under the same properties and principles and share similar user interfaces Best of all many of the common raste
176. the Raster menu is not visible make sure that the gdal plugin has been activated under the plugins menu In the Raster Bands double click on drg_central_park 1 to add it to the expression Hit the equals symbol under the Operators Then type the number 5 the green pixel class that represents wooded areas in the expression box Under the result layer section keep the box checked that says Add result to project and keep the output format as GeoTIFF Lastly browse under Output layer to create a new file in your part2 folder called drg_trees Then hit OK and wait a few seconds for the operation to process Z Raster calculator i Y 2K Raster bands Result layer drg_central_park 1 Output layer rac gis_prac_data part2 drg_trees Current layer extent X min 981255 47393 XMax 1022217 38112 Y min 206549 17112 Y max 261119 89713 A b 2 kod a Columns 5141 y Rows 6849 Output format GeoTIFF X Add result to project wv Operators Raster calculator expression drg_central_park 1 5 Expression valid 5 Examine raster output In the ML move the DRG_TREES raster near the top of the menu but just below the suBways layer so that you have some context and zoom in to the area around Central Park This example simply demonstrates how rasters differ from vectors and how you can work with them to extract features Layers l i gt fe ES 3 X subway_stations drg_trees 0 0 999 x greenspace x faci
177. the number of left segments to o and the right F Donnelly Baruch CUNY 2015 rig CC BY NC ND 4 0 4 5 DESIGNING MAPS CHAPTER 4 THEMATIC MAPPING segments to 3 Lastly under Fonts and colors change the font size to 10 Use the select move button to position the scale bar on your map This is the simplest way to create a scale bar out of the box if you want more control over its configuration see the commentary that follows this section Save your project Composition Item properties Atlas generation Item properties xX Scalebar Y Main properties Map Map 0 z Style Single Box z vw Units Feet z Label miles Map units per bar unit 1000 000000 v Segments Segments left 0 right 3 es Size 250000 000000 units 4 4 Pb 4 Height 3 mm 12 Balance your map elements At this point you should have all of your map elements in place You may need to resize and shift elements around in order for the map to appear balanced If you want to insure that boxes are lined up properly you can hit the select move button and click on individual features while holding down the CTRL key to select multiple items You can use the various align buttons to arrange elements in a certain way and you can use the group button to bind several features together so you can move them in unison Save your project Voter Participation in he 2012 Election Mi Otizens who Voted A ercer Total C 478 55 9 Seura US
178. this in creating 195 Neigh borhood Tabulation Areas NTAs While the NTA s would be more neighborhood like using them would create extra work for us as we would have to aggregate all of our demographic data PUMAs would also give us units of equal population size to study 100k residents for each and the census estimates would be more precise since the population size is larger But PUMAs are large enough that they would mask a lot of variability within each area as there are only 55 of them in NYC ZCTAs are readily recognizable to most people and are frequently used in marketing and real estate applications for approximating neighborhoods But ZIP Codes were never designed for studying neighborhoods they were designed in the mid 20th century for delivering mail and they vary tremendously in size shape and population They also don t mesh well with other types of geography TIGER Line Files The Census Bureau creates and maintains legal statistical and administrative boundaries for all geographic ar eas that it publishes data for It also creates and maintains geographic features such as water roads and land marks that are used when creating statistical boundaries These files were originally in a vector format created by the census called Topologically Integrated Geographic Encoding and Referencing or TIGER The Census now provides this data in shapefile format The files are in the public domain and can be downloaded for free at
179. tizing File Help Label Manage Layers and Map Navigation If other features are checked uncheck them Every time you check or uncheck a feature the toolbar view menu will disappear so you will need to right click on a blank area of the toolbar to get it back Move toolbars Move the toolbars around by hovering over the left edge of a toolbar until you see a crosshairs left click and hold then drag and drop Configure the toolbars to your liking suggestion try aligning them so you have only two rows of them at the top of the screen and all buttons are visible Un stack the browser and map legend To keep our interface less cluttered we re going to modify the configuration of our browser and map legend from a stacked view where they appear together one on top of the other to a tabbed view where only one is visible at a time At the top of the browser left click on the Browser title and drag the box down over the layers box and release The browser will now occupy the entire space At the bottom of the screen you ll now see tabs where you can switch back and forth from the browser to the layers view 11 2 1 THE QGIS INTERFACE CHAPTER 2 EXPLORING THE INTERFACE 2 1 2 Commentary Interface Components 1 Menu Bar provides access to various features and functions of the software using a standard hierarchical menu The location of the menus and menu items is fixed although if you activate certain plugins they may add
180. to GIS concepts and applications using QGIS This chapter will cover the next steps you can take on your own 5 1 Finding Data Throughout this tutorial you ve been provided with data that you ve used to work through various exercises Once you re working on your own projects you ll need to find or create the data you need There is a lot of free GIS data available on the web created by various government agencies academic and non profit organizations and private companies You can try a search engine or look at an academic map GIS library website for a list of helpful links a list of suggestions is included in the following section To be strategic about your search it helps to understand who creates and provides the data Global international Look at supra national agencies like the United Nations in particular the UN s Envi ronment Programme has a good site or academic non profit organizations who have enhanced and updated public domain data such as the Global Administrative Areas GADM site the DIVA GIS data page and the Natural Earth project If you need satellite imagery the best sites to visit are the USGS and NASA Country level In some cases you ll want to visit a few of the international sites like DIVA GIS and Natural Earth to get basic country level datasets like state or provincial boundaries But in many instances you may want to visit a mapping agency website or data depository for the specific country you re
181. to see the structure of the file and all of its elements and attributes E Donnelly Baruch CUNY 2015 26 CC BY NC ND 4 0 Chapter 3 Geographic Analysis The goal of this chapter is to introduce some analysis and geoprocessing tools and techniques using a site selection problem as an example Over the course of this exercise you ll learn how to create a new project from an existing one create a subset of a layer and process it to create land boundaries join an attribute table to a shapefile map the attributes of a shapefile take a list of coordinates and convert it to a shapefile draw buffers around a set of features select features based on their attributes and their spatial relationship to other features and connect to a Web Mapping Service The object of this particular exercise is to identify potential areas within New York City for locating a neighborhood coffee shop Market research suggests that the primary demographic group that drinks coffee and visits coffee shops are women aged 18 to 49 Based on this research we will identify neighborhoods where this group represents a high percentage of the total population and areas where median household income is not too high indicating that rent would be prohibitively expensive We will also focus on areas that are within close proximity to subway stations as these tend to be high traffic commercial areas while avoiding areas where numerous competitors already exist 3 1 Creating New Pro
182. to the poles The distance between degrees of latitude is relatively consistent but is also not equal to a degree of longitude which requires us or software to make complex calculations to transform degrees into simple distance measurements In our example we chose to dissolve the boundaries of the buffers where they intersected because we were interested in the total area within 1 3 mile of any subway station The resulting shapefile consisted of a single feature the entire buffer What if we wanted to preserve the individual boundaries of each buffer We would leave that Dissolve box unchecked The resulting shapefile would consist of several features one buffer for each station AND each feature would take the attributes of the station it surrounds i e the station id name trains etc Site Selection Site selection theories and land use analysis can be traced back to the early 19th century with the introduction of Von Thunen s land rent gradient Subsequent work that included Weber s median location Hotelling s competitive location problem Christaller s Central Place Theory and Tobler s Laws of Geography have provided a framework for the science and art of optimal site selection Optimal site selection is studied within the fields of geography location F Donnelly Baruch CUNY 2015 53 CC BY NC ND 4 0 3 6 DRAWING BUFFERS AND MAKING SELECTIONS CHAPTER 3 GEOGRAPHIC ANALYSIS science and operations management and has expa
183. ton again and uncheck the box to turn the labels off Y Layer labeling settings Y E oa X Label this layer with trains z v Text Buffer sample gt Lorem Ipsum EJ El Lorem Ipsum abe Text Text style 2 4 2 Commentary Attribute Tables Every vector feature has a record in the attribute table you can t have a feature without an attribute or vice versa In a shapefile the geometry is stored in the shp file an index of the geometry is in the shx file and the attributes are stored in a dbf file As we ll explore throughout this tutorial attributes can be used for selecting symbolizing and labeling features in layers In GIS software attribute tables are managed and handled in the same manner as tables in a relational database Each column has a data type associated with it which determines the kind of data that can be stored in that column and the types of operations that can be performed on it Data types include strings aka text and various types of numeric fields integers for whole numbers reals for numbers with decimal places etc When you use the Expression Builder to select features like bcode 36005 you are actually creating SQL code which is a standard language for manipulating data in a database The code 36005 must be surrounded by quotes as the data is an identifier saved as a text or string field if we were querying actual numeric values we would not use quot
184. ual GPS units as a default and is commonly used by online mapping applications It is so common that it is often referred to a THE Geographic Coordinate System There are other systems in North America NAD 83 North American Datum of 1983 is widely used particularly by government agencies It uses GRS 1980 as a spheroid NAD 83 as the datum and lat and long as the coordinate system If you add a map projection as the fourth element to the spheroid ellipsoid datum coordinate system trio you have a projected coordinate system PCS which is defined on a flat two dimensional surface Projection Map Projections are mathematical systems for taking the three dimensional earth and transforming it to a flat two dimensional surface There is no way to take a 3D shape and accurately represent it on a 2D surface so map projections are designed to preserve one quality of the earth area shape or distance direction or are created as a compromise to make the earth appear the way we expect it to appear on a flat surface In our previous examples we transformed our countries layer from the GCS WGS 84 to a PCS called Mollweide This projection preserves equal areas and true direction from the center of the map and is commonly used in environmental sciences for mapping things like global temperature or precipitation It uses a datum and spheroid based on WGS 84 and the coordinate system is in meters We subsequently transformed the layer into another PCS c
185. uct a site selection analysis you must understand the context study the industry or business you are interested in do some market research make sure you re familiar with the geographic environment you re working with and choose your geographic units of analysis and indicators carefully Web Mapping Service A web map service WMS is an open standard for serving georeferenced maps via the web WMS layers are saved in a geodatabase system on a webserver and are typically rendered as raster based tiles via a website or a desktop based GIS program when a client connects to a host and requests the layer As an end user zooms closer or further the actual map that s rendered may switch from showing a generalized small scale map for a large area to a detailed large scale map for a small area WMS layers are particularly valuable as a source for base maps In our example we wanted to provide a stylized map that depicted streets and major features without having to go through the trouble of downloading and stylizing a number of vector layers which is time consuming or downloading and stitching together several rasters which consumes a lot of time and disk space Finding a WMS is a simple matter of searching the web to retrieve the address and sometimes password for the service so that you can connect to it using your GIS software A few useful examples F Donnelly Baruch CUNY 2015 54 CC BY NC ND 4 0 3 7 SCREEN CAPTURES CHAPTER 3 GEOGRAP
186. ughs prj 2nd Shapefile boroughs shp boroughs shx facilities prj 3rd Shapefile facilities shp facilities shx greenspace dbf greenspace prj 2 Add the five shapefiles Maximize QGIS to return to the program On the Tool Bar hit the Vo add vector layer button When the Add Vector Layer box appears hit the Browse button Browse through the folder list to the data folder for part 2 In the Files of Type dropdown at the bottom of the window make sure the ESRI shapefiles option is selected Select the first layer in the list hold down the shift key then select the last layer This should select all five shapefiles Hit Open to add them Your layers should appear in the Map Legend and Map View make sure that you tab from the Browser to the Layers view so you can see them F Donnelly Baruch CUNY 2015 13 CC BY NC ND 4 0 2 2 ADDING VECTOR DATA CHAPTER 2 EXPLORING THE INTERFACE Open an OGR Supported Vector Layer G Q bh gis_prac gt gis_prac_data gt part2 v Search part2 pl Organize y New folder E fi HE Desktop Name Date modified Type J Downloads i s b_boundary shp 7 31 2013 1 46PM SHP File Recent Places boroughs shp 7 31 2013 1 45PM SHP File A facilities shp 7 31 2013 1 44 PM SHP File Libraries greenspace shp 7 31 2013 1 44 PM SHP File 3 Documents z subway_stations shp 7 31 2013 1 43 PM SHP File 2 Music Pictures amp Videos amp Com
187. uotes or will automatically do it when exporting data tables out as CSV The LibreOffice OpenOffice Calc spreadsheet does provide you with the ability to surround text fields with quotes and to choose delimiters when exporting data as text under Save As choose file type and check option to Edit Filter values Microsoft Excel does NOT provide this capability in order to preserve text values youd have to insert quotes manually or with formulas like concatenate Excel generally does a poor job at working with the CSV format in order to preserve data when opening a CSV in Excel always open a blank spreadsheet and import the data using the From Text tool on the Data ribbon rather than clicking on the file or opening it within Excel Another option you can use to specify data types for CSVs is to create a CSVT file which is a file that contains instructions for designating data types You must create these by hand in a text editor and provide a data type for every column in your CSV The names of the data types are placed in quotes and separated by commas The file must have the same name as the CSV file must be saved with the extension csvt and must be stored in the same directory as the csv See the example below The following data types are supported e Integer for whole numbers Real for decimal numbers String for text Date YYYY MM DD Time HH MM SS nn DateTime YYYY MM DD HH MM SS nn hc_emp_bls_2010 csw Note
188. ve access to these courses check with the library or GIS lab on your campus to find out more Once you re familiar with QGIS the leap to one of the proprietary packages isn t too great because they use a similar interface and operate under the same basic principles ArcGIS is well documented there are many books and online tutorials On the flip side the software is more resource intensive is only available for the Windows operating system and is expensive enough that it s not a viable option for an individual user You can download and sample a basic freeware version called ArcGIS Explorer from ESRI s website F Donnelly Baruch CUNY 2015 92 CC BY NC ND 4 0 Appendices Appendix A QGIS Desktop Browser The data browser makes it easier to manage your files and add them to your projects In addition to the browser that s embedded in the map interface there is also a separate browser application the QGIS Browser which offers additional features It is a convenient application for previewing your layers This section will give you a brief overview A Steps 1 Launch QGIS Browser Launch the QGIS Browser If you re using Microsoft Windows look under the Start Menu gt All Programs gt QGIS gt QGIS Browser 2 Drill down to the Part 3 Folder The folder tree here is similar to the browser that is in QGIS Desktop You can drill down through folders in your file system or you can view the contents of spatial databases or we
189. view to get information about that station Where is this information coming from IS xX Project Edit View Layer Settings Plugins Vector Raster Database Help A f A MSA DA a2 A 7 Ay A a a O a JR AOBPE SREP LA M B 2 abc abe y Identify Results v Layers d E E E amp 9 ag m ai Gosu Value x os E subway_stations x facilities E stop name 66 St Lincoln Center x boroughs Derived X b_boundary amp Actions stop_id 124 stop_name 66 St Lincoln Center trains 1 complex_id mn060 multi_st NULL bcode 36061 stop_lat 40 773440000000001 stop_lon 73 982208999999997 Mode Current layer z Auto open form i View Tree v Help Browser Layers i Cy Zoordinate 3 Open the attribute table With the subway layer still selected in the ML right click on the layer and select Open attribute table alternatively you could click the open attribute table button on the toolbar For every station feature in the subway layer there is a record for the station in the attribute table of that layer Explore the table by scrolling across it and down 4 Select a feature from the table Sort the table by clicking on the field column heading that contains the name of the station stop_name Click on the record for 137 St City College in the table Close the attribute table Zoom to the area around City College in Harlem just north of Central Park and you ll see it
190. w Select it and hit OK Back on the the Save As menu make sure the Add saved file to map box is checked Browse and save the file in your part 4 folder as sraTes_LCc sHP Hit Save then OK Wait a few seconds for the file to be created and added F Donnelly Baruch CUNY 2015 66 CC BY NC ND 4 0 4 2 TRANSFORMING MAP PROJECTIONS II CHAPTER 4 THEMATIC MAPPING g Save vector layer as El g Coordinate Reference System Selector Select the coordinate reference system for the vector file The data points will be Format ESRI Shapefile transformed from the layer coordinate reference system Save as ac_data part4 states_lcc shp Browse CRS Selected CRS EPSG 102009 North_Al v Filter north america lambert Encoding System Recently used coordinate reference systems _ Save only selected features Coordinate Reference System Authority ID Skip attribute creation mpe qng ee eee oe ee X Add saved file to map Symbology export No symbology x Scale 1 50000 E Extent current layer iL Ile Cancel Coordinate reference systems of the world Hide deprecated CRSs Coordinate Reference System Authority ID E te Projected Coordinate Systems E Lambert Conformal Conic North_America_Lambert_Conf EPSG 102009 Selected CRS North_America_Lambert_Conformal_Conic proj Icc lat_1 20 lat_2 60 lat_0 40 lon_0 96 x_0 0 y_0 0 datum NAD83 units m no_defs 4 Reset the CRS in the window Selec
191. what coordinate reference systems CRS are and how they work both in general and in QGIS in particular Choosing a CRS for your layers is of critical importance all layers in a project need to share the same system in order to work together and the choice of a system is influenced by the type of analysis you re doing and what your final map will depict 4 1 1 Steps 1 Create a new project Open QGIS to an empty blank project Hit the Ed save as button Browse to your data folder for part 4 and save the project as practice gcs We ll be working with this project for this first section of the chapter 2 Check the shapefiles CRS Minimize QGIS and use your computer s file browser to browse through the data folder for part 4 You ll see there s a shapefile in the folder called NE_50mM_apMIN_o_couNTRIES which represents countries of the world It has several files associated with it including a shp dbf shx and a prj Open the prj file in a text editor if using Windows select the file right click select a program from a list of installed 57 4 1 1 TRANSFORMING MAP PROJECTIONS I CHAPTER 4 THEMATIC MAPPING programs select Notepad and click OK You will see the projection information stored in the file GEOGCSL WGS 84 DATUML WGS_1984 SPHEROIDL WGS 84 6378137 298 257223563 AUTHORITY EPSG 7030 AUTHORITY EPSG 6326 PRIMEM Greenwich 0 AUTHORITY EPSG 8901 UNIT L degree 0 017453292519943
192. would need to take our usual step of selecting the features in the ML and doing a Save As to create a new file with the data permanently attached to it In this case since we re simply going to symbolize and map the data we don t need to take this extra step The dynamic join will be saved within this specific project and as long as the data table and states features are both present in the project the data will remain joined For whatever reason if you do find that you re having problems classifying and symbolizing the joined data then just take the extra step create the new shapefile with the data fused to it and any problem will likely go away 4 3 2 Commentary Calculated Fields In this example a well formed version of the original voting table was created in advance in our Excel spreadsheet It includes a number of derived fields that showed percent totals Although we will not cover it here QGIS does have a ES field calculator that will allow you to create new fields or modify existing ones For example you can add a new E Donnelly Baruch CUNY 2015 70 CC BY NC ND 4 0 4 4 CLASSIFYING AND SYMBOLIZING DATA CHAPTER 4 THEMATIC MAPPING field and calculate a ratio or percent total for other values within QGIS if your data table lacked that information You can also use special functions that will calculate the coordinates length area or perimeter of features Generally speaking there are some circumstances where it may make
193. xamples There are also a growing number of universities who are collaborating to create meta sites that provide geographic data at a variety of scales across the globe the Open Geoportal community is one such group e geogratis gc ca geogratis search lang er Cc 9 geogratis P A 2 t Gouverne du Canada Natural Resources Canada s Help GeoGratis Search Discover and Download Free Maps Data and Publications Complete the Following 1 Geographic Location Place Name or Postal FSA K1G or National Topographic System NTS number 2 Subject Keywords Title Theme Author Product etc 3 Product Type Maps published maps Data vector tabular etc Remotely Sensed Data satellite airborne sonar etc Regardless of where you download your data you ll want to examine the metadata for the layers Metadata can be formally or informally described on the website where you downloaded your files in narrative documentation that is included with the files you downloaded or in special XML files that accompany each of your GIS files There are a few well defined standards such as the FGDC and ISO 19139 that data creators use to document data and include elements that explain who created the data when it was last updated what the file contains what the intended purpose of the file is if it was created for a specific optimal scale the coordinate system and map projection it was created in and
194. y Local Local governments may have portals where they provide administrative boundaries transportation data and real estate or tax parcels and datasets that would be of local interest such as 87 5 1 FINDING DATA CHAPTER 5 GOING FURTHER neighborhood boundaries that may not be formally defined elsewhere You can also look at the geography one step above state level to see if data is available for the local area e Gazetteers and Geocoding If you can t find an existing GIS dataset you can always try to create one from an online gazetteer that provides latitude and longitude coordinates for point based features the USGS has a US level gazetteer while the NGA has an international gazetteer Do you have a list of addresses but no coordinates You can use the QGIS geocoding plugin to match them using Google s or OpenStreetMap s network or you can upload them to a free geocoding service like the one at Texas A amp M GIS Laboratory which will translate your addresses into coordinates e In some cases you may find university or non profit sites that provide data within a specialized area of interest While universities typically provide data for the geographic areas where they reside there may be special labs or research groups that provide data beyond that area the CIESN Center for International Earth Science Information Network site at Columbia University and the NHGIS National Historic GIS at the University of Minnesota are two e
195. y colors and outlines will vary 4 6 Adding Labels In this section we ll go back and add some labels to our map The labeling system can be accessed via two places via the Labels tab under the Properties menu for a particular layer or with a layer selected in the ML via the labels button on the toolbar 4 6 1 Steps 1 Turn labels on Close the print composer and go back to your QGIS map view Select stares Lcc in the ML and hit the labels button on the toolbar or double click on the layer and go to the labels tab On Label Settings check the box to Label this layer In the Fields with labels dropdown choose USPS as the label field this field has the two letter postal code for each state In the Text menu change the size of the text to 8 0 In the Buffer menu check the box to Draw text buffer Hit OK to apply the label settings gZ Layer Properties states_Icc Labels E 2S S lt General X Label this layer with a USPS y Style w Text Buffer sample Labels Lorem Ipsum is Fields Rendering Lorem Ipsum Y v g Display o Text Text style Actions 2 Formatting 10 v B se Buffer Font MS Shell Dig 2 Joins Back d a A Style Normal ER Diagrams 2 ee mm A a Placement u Else e 6 amp 6 18 4 Metadata Rendering z 1 E Size 8 0000 G points Jak Load Style Save As Default Restore Default Style Save Style Z OK Cancel Apply Help
196. y many academic and public libraries You can search for businesses by name industrial classification code and geography and download the data in spreadsheet format although the number of records you can access in one download is limited They provide comprehensive business health care and residence data for the US and Canada The inclusion of XY coordi nates longitude and latitude for each record makes it possible to plot the data in GIS Ultimately the outcome of this exercise is only as good as the input when downloading this type of data you must scrutinize it to make sure that you capture as many records that meet your criteria as possible while removing ones that do not Don t accept the data as is consider it as raw data that you must analyze and clean before bringing it into GIS For example in assembling the coffee shop dataset for this exercise many businesses self identified based on SIC or NAICS codes as coffee shops but based on the name of the business they were actually cafes or diners in New York the term coffee shop is often synonymous with diner think of the coffee shop in Seinfeld episodes As a diner is not what we had in mind these records had to be removed At the same time a popular local chain of coffee shops was missing in the initial set of records subsequent investigation revealed that they identified themselves primarily as coffee roasters and not as retail shops even though they engage in both activities T
Download Pdf Manuals
Related Search
Related Contents
Manual - Microh 466000076 service manual AM-USA CFE65 User manual - MikroElektronika Copyright © All rights reserved.
Failed to retrieve file