Learn R Programming

hansard (version 0.4.0)

election_results: election_results

Description

Imports data on general election results

Usage

election_results(ID = NULL, extra_args = NULL, tidy = TRUE)

Arguments

ID

Accepts an ID for a general or by-election from the 2010 general election onwards, and returns the results. If NULL, returns all available election results. Defaults to NULL.

extra_args

Additional parameters to pass to API. Defaults to NULL.

tidy

Fix the variable names in the data frame to remove extra characters, superfluous text and convert variable names to snake_case. Defaults to TRUE.

Examples

Run this code

x <- election_results(ID=382037)

Run the code above in your browser using DataLab