Giter Site home page Giter Site logo

anesr's Introduction

anesr: Easy access to ANES data in R

The American National Election Studies are one of the most important sources of data for political scientists. anesr provides easy access to ANES data for R users. anesr includes tidy versions of all ANES pilot and time series studies as compact, rda objects. Once the package is installed and loaded, any dataset can be accessed using the data() function. anesr also includes documentation for some studies in tidy format. Documentation files include descriptions, coding, and marginals or summary statistics for all variables in the dataset.

Installation

To install anesr, use the install_github function from the devtools package:

library(devtools)
install_github("jamesmartherus/anesr")

Examples

library(anesr)

data(package="anesr") #View a list of available datasets

data(timeseries_cum) #Load Time Series Cumulative File (1948-2016)
data(timeseries_cum_doc) #Load documentation for the Time Series Cumulative File

data(pilot_2018) #Load 2018 Pilot Study

Terms of Use

By using these data, you agree to the terms of use established by the ANES:

  • Use these datasets solely for research or statistical purposes and not for investigation of specific survey respondents.
  • Make no use of the identity of any survey respondent(s) discovered intentionally or inadvertently, and to advise ANES of any such discovery ([email protected])
  • Cite ANES data and documentation in your work that makes use of the data and documentation. Authors of publications based on ANES data should send citations of their published works to ANES for inclusion in our bibliography of related publications.
  • You acknowledge that the original collector of the data, ANES, and the relevant funding agency/agencies bear no responsibility for use of the data or for interpretations or inferences based upon such uses.

ANES is not responsible for any errors in these datasets - any mistakes are mine.

Acknowledgments

anesr's People

Contributors

jamesmartherus avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

anesr's Issues

no data yet?

I recently started doing some work with the ANES surveys and was excited to see this handy way to access the various datasets in R. However, I just followed your README installation instructions and everything seemed to go well up to the actual data(dataset_name) command, which failed. Here's my jupyterlab notebook:

image

The commented-out commands ran successfully per your README. The data(package="anesr") command then worked as expected, listing 46 packages (collapsed in this screenshot), but as you can see, the data commands for both datasets and docs produced a “data set ‘timeseries_2016’ not found” response.

Is the data not there yet? or maybe there is a step in the process I've left out?

Filter Error with Time Series 2020 Data

Hi there,

Ran into the following issue when filtering the timeseries_2020 data. I had no issues using the cumulative time series file with what were essentially the same commands.

After loading up dplyr, devtools, and anesr, I ran the following commands:

data(timeseries_2020) datadems2020 <- timeseries_2020 %>% filter(V201228 == 1)

This resulted in the following:

See Screenshot

That being said, anything that involves playing with the data seems to result in that same error:

Screenshot

This could very well be user error, I am quite rusty when it comes to R, but reaching out in case it is a data or package issue.

Thank you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.