For this project, I visualized the crime counts per LSOA (Lower Super
Output Area) in the city of Manchester.
All credit for the instructions and data go to Crime Mapping and Spatial Data Analysis using R by Juanjo Medina and Reka Solymosi.
Code can be found below.
library(readr)
library(dplyr)
library(janitor)
library(skimr)
library(sf)
library(tmap)
library(tmaptools)
library(DCluster)
library(geodaData)
manchester = st_read("https://raw.githubusercontent.com/maczokni/crime_mapping/master/data/manchester.geojson", quiet = TRUE)
tm_shape(manchester) +
tm_bubbles("count", col = 'red', border.lwd=NA) +
tm_borders(alpha=0.7) +
tm_layout(legend.position = c("right", "bottom"),
legend.title.size = 0.8, legend.text.size = 0.5, bg.color ='#CCE5FF', title = "Manchester")