GE2014 {nzelect}R Documentation

General Election Results 2014

Description

New Zealand 2014 general election results by voting place

Usage

GE2014

Format

A data frame with 136,195 rows and 7 variables.

Details

GE2014 is deprecated; please use nzge instead - it has results back to 2002 and is the one we will update in future.

Source

http://www.electionresults.govt.nz/electionresults_2014/e9/html/statistics.html

See Also

Locations2014

Examples

# the following matches the results published at
# http://www.electionresults.govt.nz/electionresults_2014/e9/html/e9_part1.html
library(tidyr)
library(dplyr)
GE2014 %>%
    mutate(VotingType = paste0(VotingType, "Vote")) %>%
    group_by(Party, VotingType) %>%
    summarise(Votes = sum(Votes)) %>%
    spread(VotingType, Votes) %>%
    select(Party, PartyVote, CandidateVote) %>%
    ungroup() %>%
    arrange(desc(PartyVote))

[Package nzelect version 0.4.0 Index]