rudeboybert / fivethirtyeight

R package of data and code behind the stories and interactives at FiveThirtyEight
https://fivethirtyeight-r.netlify.app/
Other
455 stars 107 forks source link

csv's in README rather than data-raw folder #53

Closed kvanallen closed 4 years ago

kvanallen commented 4 years ago

I wanted to convert some data files from the data-raw folder into .rda files so more data will be available to users of the package, but I noticed that some of the data is only in the README.md file, and not in the actual data-raw folder themselves. I was wondering why this is the case and if the way to extract them is the same?

example: nba-forecasts

rudeboybert commented 4 years ago

Thanks for your message @kvanallen. Tagging @beanumber

It's a subtle point, but the README for nba-forecasts has links to "dynamic" .csv's that 538 updates periodically, as opposed to "static" .csv files that are straight posted to the repos. Think of these as a data "streaming" feed. This is to ensure so that users will always have access to the most update-to-date version of the data. You can see other examples of such "dynamic" data in column N of the following Google Sheet; they are tagged with "Y".

In the case of the fivethirtyeight package, we include a snapshot of the data as it is on 538's GitHub on a particular date, and then make sure to update these "dynamic" datasets every time we update the package. As an example, see the data wrangling of fivethirtyeight::senate_national_forecast, which is based on the senate-forecast-2018 from 538.

rudeboybert commented 4 years ago

Resolved in #63