Description Usage Arguments Value Examples
View source: R/fars_functions.R
This function creates a map of the accident locations for a given state and year. Returns an error message of Invalid year: <value> if the year value is not between 2013-2015. Returns an error message of Invalid STATE number: if the state number is not one of the States included in the data. Returns an error of no accidents to plot if there are no accidents for the specified state number and year.
1 | fars_map_state(state.num, year)
|
state.num |
Integer value between 0 and 50. |
year |
The year |
a map object. Prints the map as a side-effect.
1 2 3 4 5 | ## Not run:
fars_map_state(1, 2014)
fars_map_state(20, 2015)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.