I stumbled upon this tutorial while not studying and I thought it would be fun to try and plot maps of the San Francisco Bay Area household income, education, population density, poverty, etc…
To do this I needed a Shapefile for the Bay Area zip codes similar to the London borough file used in the tutorial. I found a .shp file for the Bay Area zip code boundaries here.
I have a demographic database on my computer that I used to add the needed information to the Shapefile. In the code I included a vector of the median household incomes for the corresponding zipcodes in the the .shp file.
The following code is only slightly modified from the code included in the Spatial Analysis tutorial.
## set the working directory.
## load the shapefile
This is the map that results from the code above.
Here is a visualization of the population density in the Bay Area.
Finally, here is a visualization of the percent of adults (25 years or older) with a bachelors degree or higher.
I’m not familiar with GIS software so I imagine that this is sort of a round about way of doing something pretty simple, but I think the results are cool.