Description Usage Arguments Value Examples
View source: R/fars_functions.R
Groups together in a new dataframe all accidents by selecting only the month and the year referenced in the archive files "accident_year.csv.bz2" from the target years given in the input. This function calls make_file_name and fars_read.
1 | fars_read_years(years)
|
years |
An integer vector with all the years to extract |
If the input is an integer vector as required, it returns a dataframe with n+1 columns : MONTH and n years. Otherwise, when there are no archive files with the target year, it returns a warning like "invalid year: year" and NULL value.
1 2 | fars_read_years(c("2013", "2014")) -> success
fars_read_years(c(2013, 2014)) -> success
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.