View source: R/fars_functions.R
fars_read_years | R Documentation |
This function takes a list of years and creates file names for each of
them using the make_filename
function.
It then reads in these files using the fars_read
function and
creates a list of tibbles which contain the months in each of the
years.
If the file name created from a year inputted does not correspond
to an existing file containing data for said year, an error is thrown.
fars_read_years(years)
years |
A list or vector of years. |
A list of tibbles, each with two columns: one containing the months, and the other containing the year. The number of rows for each month represents the number of accidents in the month. This list is also printed.
## Not run: fars_read_years(c(2014,2015)) ## Not run: fars_read_years(c(2013,2014))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.