Title: | German Election Database (GERDA) |
---|---|
Description: | Provides tools to download comprehensive datasets of local, state, and federal election results in Germany from 1990 to 2021. The package facilitates access to data on turnout, vote shares for major parties, and demographic information across different levels of government (municipal, state, and federal). It offers access to geographically harmonized datasets that account for changes in municipal boundaries over time and incorporate mail-in voting districts. Users can easily retrieve, clean, and standardize German electoral data, making it ready for analysis. Data is sourced from <http://www.german-elections.com>. |
Authors: | Hanno Hilbig [aut, cre] |
Maintainer: | Hanno Hilbig <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.0 |
Built: | 2024-11-21 05:12:20 UTC |
Source: | https://github.com/hhilbig/gerda |
This function lists the available GERDA data sets. The purpose of this function is to quickly provide a list of available data sets and their descriptions.
gerda_data_list(print_table = TRUE)
gerda_data_list(print_table = TRUE)
print_table |
A logical value indicating whether to print the table in the console (TRUE) or return the data as a tibble (FALSE). Default is TRUE. |
A tibble containing the available GERDA data with descriptions. When print_table = TRUE, the function prints a formatted table to the console and invisibly returns the data tibble. When print_table = FALSE, the function directly returns the data tibble.
gerda_data_list()
gerda_data_list()
This function loads GERDA data from a web source.
load_gerda_web(file_name, verbose = FALSE, file_format = "rds")
load_gerda_web(file_name, verbose = FALSE, file_format = "rds")
file_name |
A character string specifying the name of the file to load. For a list of available data, see |
verbose |
A logical value indicating whether to print additional messages to the console. Default is FALSE. |
file_format |
A character string specifying the format of the file. Must be either "csv" or "rds". Default is "rds". |
A tibble containing the loaded data, or NULL if the data could not be loaded.
data_municipal_harm <- load_gerda_web("municipal_harm", verbose = TRUE, file_format = "rds")
data_municipal_harm <- load_gerda_web("municipal_harm", verbose = TRUE, file_format = "rds")