Description Usage Arguments Details Value Source
This function extracts data, in csv format, from the users current work directory. This function is called by the fars_read_years and fars_map_state functions. It is not called on its own. This file is not exported to the user. Data is extracted using the readr package. Once the data is read into R the dplyr package alters the look of the data frame using the tbl_df function.
1 | fars_read(filename)
|
filename |
A character string providing the file location of the US National Highway Safety Administration's Fatality Analysis Reporting System data. The filename is constructed in the make_filename function, so this parameter should never have to be input direclty. |
an error will be thrown if the filename does not exist, or is not in the current working directory telling the user the file does not exist.
The function returns a tbl_df, tbl, data.frame object ready for manipulation.
Data is found at the US National Highway Traffic Safety Administration's Fatality Analysis Reporting System
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.