fars_map_state: Plot accident data per state

Description Usage Arguments Value Examples

Description

This function will plot the accidents for a selected state and year. If the state number is not a valid integer or numeric, the function will stop with an error message. The function will also return an error if the year is invalid

Usage

1
fars_map_state(state.num, year)

Arguments

state.num

A numeric or integer value representing the state in the Fatality Analysis Reporting System

year

A numeric or integer valaue representing the year that needs to be plotted

Value

Returns a plot of all accidents using the state.num and year parameters. Returns an error if the state number or year is invalid.

Examples

1
2
3
4
5
6
7
8
## Not run: 
fars_map_state(25,2014)

# Error
fars_map_state(111,2014)
fars_map_state(25,2016)

## End(Not run)

pvisser82/fars documentation built on May 29, 2019, 7:50 a.m.