'nycflights13' package is not found


#1

Hello. I'm new to R and learning using "R for Data Science" online book http://r4ds.had.co.nz/transform.html#introduction-2 . In Section 5.1 on how to use dplyr packages, I am having a similar issue where the 'nycflights13' package is not found. Have updated, restarted, etc. but no luck. Any help is appreciated.


Using summarise() and group_by() in RStudio
#2

Did you install it? You can install it with install.packages().


#3

I guess I assumed it would be there like all the previous packages (mpg, diamonds, etc.). install.package per your suggestion seems to have done it. Thank you. Guess that's a mulligan.


#4

These distinctions definitely aren’t super obvious when you’re just starting out! diamonds and mpg are two of the example datasets that come bundled with the ggplot2 package. As you just discovered, nycflights13 is an entire package itself (that contains several tables of related data).


#5

Indeed.

A good trick vikg, if you aren't sure, is to google "r package-name" :slight_smile: If the package is on CRAN, you will find the manual:

https://cran.r-project.org/web/packages/nycflights13/index.html