Skip to content

Commit

Permalink
CRAN resubmission
Browse files Browse the repository at this point in the history
  • Loading branch information
rudeboybert committed Jan 8, 2017
1 parent e3fc313 commit ab61824
Show file tree
Hide file tree
Showing 9 changed files with 36 additions and 41 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: fivethirtyeight
Title: Data and Code Behind the Stories and Interactives at FiveThirtyEight
Description: Data and code behind the stories and interactives at FiveThirtyEight
\url{https://github.com/fivethirtyeight/data}.
Description: Data and code behind the stories and interactives at 'FiveThirtyEight'
<https://github.com/fivethirtyeight/data>.
Version: 0.1.0
Authors@R: c(
person("Albert Y.", "Kim", email = "albert.ys.kim@gmail.com", role = "cre"),
Expand Down
20 changes: 1 addition & 19 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,20 +1,2 @@
YEAR: 2014
COPYRIGHT HOLDER: ESPN Internet Ventures

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
COPYRIGHT HOLDER: ESPN Internet Ventures
4 changes: 2 additions & 2 deletions R/data_chester.R
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@
#' \item{division}{NFL division}
#' \item{avg_tix_price}{Average ticket price}
#' }
#' @source StubHub \url{http://www.stubhub.com/}
#' @source StubHub stubhub.com
"nfltix_div_avgprice"


Expand All @@ -345,7 +345,7 @@
#' \item{team}{Name of NFL team}
#' \item{avg_tix_price}{Average ticket price}
#' }
#' @source StubHub \url{http://www.stubhub.com/}
#' @source StubHub stubhub.com
"nfltix_usa_avg"


Expand Down
11 changes: 11 additions & 0 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
## Summary

## Resubmission

This is a resubmission. In this version I have:

* I've fixed the LICENSE file to fit the template at <https://www.r-project.org/Licenses/MIT>
* Fixed the http://www.stubhub.com/ url
* Fixed url's for CRAN packages to be in canonical form
* Re-ran roxygen on bechdel.Rmd vignette
* Fixed description section of DESCRIPTION file


## Test environments

* local OS X install, R 3.3.2
Expand Down
2 changes: 1 addition & 1 deletion man/nfltix_div_avgprice.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/nfltix_usa_avg.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions vignettes/bechdel.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<meta name="author" content="Albert Y. Kim, Chester Ismay, and Jennifer Chunn" />

<meta name="date" content="2017-01-07" />
<meta name="date" content="2017-01-08" />

<title>Bechdel analysis using the tidyverse</title>

Expand Down Expand Up @@ -70,7 +70,7 @@

<h1 class="title toc-ignore">Bechdel analysis using the <code>tidyverse</code></h1>
<h4 class="author"><em>Albert Y. Kim, Chester Ismay, and Jennifer Chunn</em></h4>
<h4 class="date"><em>2017-01-07</em></h4>
<h4 class="date"><em>2017-01-08</em></h4>



Expand Down
13 changes: 7 additions & 6 deletions vignettes/fivethirtyeight.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ library(knitr)

## Motivation

We are all involved in statistics and data science education, in particular at the
We are involved in statistics and data science education, in particular at the
introductory undergraduate level. As such, we are always looking for data sets that
balance being

1. **Rich enough** to answer meaningful questions with, **real enough** to ensure that there is context, and **realistic enough** to convey to students that data as it exists "in the wild" needs processing.
1. **Rich enough** to answer meaningful questions with, **real enough** to ensure that there is context, and **realistic enough** to convey to students that data as it exists "in the wild" often needs processing.
1. Easily and quickly accessible to novices, so that we [minimize the prerequisites to research](https://arxiv.org/abs/1507.05346).

It has been our experience that many data sets that exist in R packages, such as the
Expand All @@ -31,15 +31,15 @@ It has been our experience that many data sets that exist in R packages, such as
packages, are of great pedagogical value as they:

* Satisfy the above two goals.
* Are in standardized format as they fit into the [tidy tools](https://cran.r-project.org/web/packages/tidyverse/vignettes/manifesto.html) ecosystem.
* Are in standardized format as they fit into the [tidy tools](https://CRAN.R-project.org/package=tidyverse/vignettes/manifesto.html) ecosystem.
* Are really fun to play with!

It is along these lines that we present `fivethirtyeight`: an R package of data and code behind the stories and interactives at [FiveThirtyEight.com](http://fivethirtyeight.com/), a data-driven journalism website founded by Nate Silver and owned by ESPN. FiveThirtyEight has been very forward thinking in making the data used in many of their articles open and accessible on [GitHub](https://github.com/fivethirtyeight/data), a web-based repository for collaboration on code and data.

With consultation from [Andrew Flowers](http://fivethirtyeight.com/contributors/andrew-flowers/) and [Andrei Scheinkman](http://fivethirtyeight.com/contributors/andrei-scheinkman/) of FiveThirtyEight, we go one step further by:

1. Doing just enough pre-processing so that statistics and data science novices can sink their teeth into the data.
2. Packaging it all in an easy to load format: package installation instead of working with CSV's.
1. Doing just enough pre-processing so that statistics and data science novices can sink their teeth into the data right away.
2. Packaging it all in an easy to load format: package installation instead of working with CSV files.
3. Providing easily accessible documentation: The help file for each data set includes a thorough description of the observational unit and all variables, a link to the original article, and (if listed) the data sources.


Expand All @@ -63,9 +63,10 @@ guidelines:
+ Factors vs characters:
+ Ordinal categorical variables are `factor` with the intuitive ordering of `levels`. We did this to ensure barplots and boxplots would display in an intuitive order.
+ Regular categorical variables are left as `character` vectors.
+ Convert date variables that are beyond just `year` to [POSIX date](http://www.epochconverter.com/) objects using the [lubridate](https://cran.r-project.org/web/packages/lubridate/vignettes/lubridate.html) package. That way users can easily create time series plots. Example:
+ Convert date variables that are beyond just `year` to [POSIX date](http://www.epochconverter.com/) objects using the [lubridate](https://CRAN.R-project.org/package=lubridate/vignettes/lubridate.html) package. That way users can easily create time series plots. Example:
+ If only a `year` variable exits, then we leave it as is.
+ If there are `year` and `month` variables, we convert them POSIX date objects as `year-month-01`.
+ If there are `year`, `month`, and `day` variables, we convert them POSIX date objects as `year-month-day`.

**Note**: The code used to pre-process the data can be found on the [GitHub repository](https://github.com/rudeboybert/fivethirtyeight/tree/master/data-raw) for the package in the `process_data_sets.R` files. These can serve as data manipulation/wrangling examples and exercises for more advanced students.

Expand Down
17 changes: 9 additions & 8 deletions vignettes/fivethirtyeight.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<meta name="author" content="Albert Y. Kim, Chester Ismay, and Jennifer Chunn" />

<meta name="date" content="2017-01-07" />
<meta name="date" content="2017-01-08" />

<title>fivethirtyeight Package</title>

Expand All @@ -32,28 +32,28 @@

<h1 class="title toc-ignore"><code>fivethirtyeight</code> Package</h1>
<h4 class="author"><em>Albert Y. Kim, Chester Ismay, and Jennifer Chunn</em></h4>
<h4 class="date"><em>2017-01-07</em></h4>
<h4 class="date"><em>2017-01-08</em></h4>



<div id="motivation" class="section level2">
<h2>Motivation</h2>
<p>We are all involved in statistics and data science education, in particular at the introductory undergraduate level. As such, we are always looking for data sets that balance being</p>
<p>We are involved in statistics and data science education, in particular at the introductory undergraduate level. As such, we are always looking for data sets that balance being</p>
<ol style="list-style-type: decimal">
<li><strong>Rich enough</strong> to answer meaningful questions with, <strong>real enough</strong> to ensure that there is context, and <strong>realistic enough</strong> to convey to students that data as it exists “in the wild” needs processing.</li>
<li><strong>Rich enough</strong> to answer meaningful questions with, <strong>real enough</strong> to ensure that there is context, and <strong>realistic enough</strong> to convey to students that data as it exists “in the wild” often needs processing.</li>
<li>Easily and quickly accessible to novices, so that we <a href="https://arxiv.org/abs/1507.05346">minimize the prerequisites to research</a>.</li>
</ol>
<p>It has been our experience that many data sets that exist in R packages, such as the <a href="https://github.com/hadley/nycflights13"><code>nycflights13</code></a>, <a href="https://github.com/hadley/babynames"><code>babynames</code></a>, and <a href="https://github.com/jennybc/gapminder"><code>gapminder</code></a> packages, are of great pedagogical value as they:</p>
<ul>
<li>Satisfy the above two goals.</li>
<li>Are in standardized format as they fit into the <a href="https://cran.r-project.org/web/packages/tidyverse/vignettes/manifesto.html">tidy tools</a> ecosystem.</li>
<li>Are in standardized format as they fit into the <a href="https://CRAN.R-project.org/package=tidyverse/vignettes/manifesto.html">tidy tools</a> ecosystem.</li>
<li>Are really fun to play with!</li>
</ul>
<p>It is along these lines that we present <code>fivethirtyeight</code>: an R package of data and code behind the stories and interactives at <a href="http://fivethirtyeight.com/">FiveThirtyEight.com</a>, a data-driven journalism website founded by Nate Silver and owned by ESPN. FiveThirtyEight has been very forward thinking in making the data used in many of their articles open and accessible on <a href="https://github.com/fivethirtyeight/data">GitHub</a>, a web-based repository for collaboration on code and data.</p>
<p>With consultation from <a href="http://fivethirtyeight.com/contributors/andrew-flowers/">Andrew Flowers</a> and <a href="http://fivethirtyeight.com/contributors/andrei-scheinkman/">Andrei Scheinkman</a> of FiveThirtyEight, we go one step further by:</p>
<ol style="list-style-type: decimal">
<li>Doing just enough pre-processing so that statistics and data science novices can sink their teeth into the data.</li>
<li>Packaging it all in an easy to load format: package installation instead of working with CSV’s.</li>
<li>Doing just enough pre-processing so that statistics and data science novices can sink their teeth into the data right away.</li>
<li>Packaging it all in an easy to load format: package installation instead of working with CSV files.</li>
<li>Providing easily accessible documentation: The help file for each data set includes a thorough description of the observational unit and all variables, a link to the original article, and (if listed) the data sources.</li>
</ol>
</div>
Expand All @@ -74,10 +74,11 @@ <h2>Guidelines</h2>
<li>Ordinal categorical variables are <code>factor</code> with the intuitive ordering of <code>levels</code>. We did this to ensure barplots and boxplots would display in an intuitive order.</li>
<li>Regular categorical variables are left as <code>character</code> vectors.</li>
</ul></li>
<li>Convert date variables that are beyond just <code>year</code> to <a href="http://www.epochconverter.com/">POSIX date</a> objects using the <a href="https://cran.r-project.org/web/packages/lubridate/vignettes/lubridate.html">lubridate</a> package. That way users can easily create time series plots. Example:
<li>Convert date variables that are beyond just <code>year</code> to <a href="http://www.epochconverter.com/">POSIX date</a> objects using the <a href="https://CRAN.R-project.org/package=lubridate/vignettes/lubridate.html">lubridate</a> package. That way users can easily create time series plots. Example:
<ul>
<li>If only a <code>year</code> variable exits, then we leave it as is.</li>
<li>If there are <code>year</code> and <code>month</code> variables, we convert them POSIX date objects as <code>year-month-01</code>.</li>
<li>If there are <code>year</code>, <code>month</code>, and <code>day</code> variables, we convert them POSIX date objects as <code>year-month-day</code>.</li>
</ul></li>
</ul></li>
</ul>
Expand Down

0 comments on commit ab61824

Please sign in to comment.