murder: Murder locations

murderR Documentation

Murder locations

Description

Locations of murders in Toronto 1990-2014

Usage

data("murder")

Format

murder is a SpatVector object of murder locations. torontoPdens, torontoIncome, and torontoNight are rasters containing population density (per hectare), median household income, and ambient light respectively. torontoBorder is a SpatVector of the boundary of the city of Toronto.

Source

Murder data:https://mdl.library.utoronto.ca/collections/geospatial-data/toronto-homicide-data-1990-2013,

Lights: https://ngdc.noaa.gov/eog/viirs/download_ut_mos.html

Boundary files: https://www150.statcan.gc.ca/n1/en/catalogue/92-160-X

Income: https://www150.statcan.gc.ca/n1/en/catalogue/97-551-X2006007

Examples

data("murder")
murder= unwrap(murder)
torontoBorder = unwrap(torontoBorder)

plot(torontoBorder)
points(murder, col="#0000FF40", cex=0.5)

data("torontoPop")
torontoNight = unwrap(torontoNight)
torontoIncome = unwrap(torontoIncome)
torontoPdens = unwrap(torontoPdens)

# light
plot(torontoNight, main="Toronto ambient light")
plot(torontoBorder, add=TRUE)
points(murder, col="#0000FF40", cex=0.5)


# income
plot(torontoIncome, main="Toronto Income")
points(murder, col="#0000FF40", cex=0.5)
plot(torontoBorder, add=TRUE)

# population density
plot(torontoPdens, main="Toronto pop dens")
points(murder, col="#0000FF40", cex=0.5)
plot(torontoBorder, add=TRUE)


geostatsp documentation built on May 29, 2024, 5:53 a.m.