Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated SurveyData function to handle haven-labelled data #159

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add data documentation for shape_survey_haven.rda.
Dewi-Amaliah committed Aug 30, 2021
commit 72288b140d4c5dba1d773609486729be69c33562
23 changes: 23 additions & 0 deletions R/data.R
Original file line number Diff line number Diff line change
@@ -57,6 +57,29 @@
#'
"shape_survey"

#' Simulated Survey Data for Shape World - Haven-labelled Version
#'
#' This is the shape_survey data with some variables saved in haven-labelled class.
#'
#' @source Created in ShapeWorldVoters.R
#'
#' @format A data frame with columns:
#'
#' \describe{
#' \item{age}{Age group; haven-labelled}
#' \item{gender}{Gender; haven-labelled}
#' \item{vote_for}{Party voted for in the 2016 election; haven-labelled}
#' \item{highest_educ}{Highest grade of education completed; haven-labelled}
#' \item{state}{State; haven-labelled}
#' \item{y}{Preference for BP over CP in 2020 election}
#' \item{wt}{Raked and trimmed survey weight}
#' }
#' @examples
#'
#' shape_survey_haven
#'
"shape_survey_haven"

#' Simulated approximate population data for the Shape World survey
#'
#' Simulated approximate population data for the [Shape World][shape_survey]