Learn R Programming

eechidna (version 1.1)

nat_data_2016: Data of the Australian Electorate from 2016

Description

A dataset containing some demographic information for each of the 150 Australian electorates. The data were obtained from the Australian Electoral Commission, and downloaded from http://www.aec.gov.au/Electorates/gis/gis_datadownload.htm. The data is published

Usage

nat_data_2016

Arguments

Format

A data frame with 150 rows with the following variables:
  • id: numeric identifier that links the electorate with the corresponding polygon in `nat_map`.
  • Elect_div: Electorate division name
  • State: abbreviation of the state name
  • Numccds: AEC variable that might be filled with meaning or a description down the road
  • Area_SqKm: combined square kilometers of each electorate
  • id Numerical id for electorate
  • long_c Centroid longitude
  • lat_c Centroid latitude

Examples

Run this code

data(nat_data_2016)
data(nat_map_2016)
library(ggplot2)
library(ggthemes)
ggplot(aes(map_id=id), data=nat_data_2016) +
  geom_map(map=nat_map_2016) +
  geom_point(data=nat_data_2016, aes(x=long_c, y=lat_c), inherit.aes=FALSE) +
  expand_limits(x=nat_map_2016$long, y=nat_map_2016$lat) + 
  theme_map()
  

Run the code above in your browser using DataLab