Description Usage Arguments Value Note Examples
This function returns a list of data files per year, as specified by the parameter years. The parameter is used to create filenames, using the make_filename helper function. If an invalid year is passed, the return value for that year is NULL
1 | fars_read_years(years)
|
years |
A numeric vector containing the years of which the FARS data is asked |
A list of data.frames or NULL if the year resulted in an invalid file
if any of the numbers in years is not valid, the list will contain "NULL" at that index, and a "invalid year" warning will be issued. Much of the detail in the data available in the FARS dataset is ignored, as only MONTH and year are selected.
1 2 3 4 | ## Not run:
fars_read_years(2015)
fars_read_years(c(2013, 2014, 2015))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.