fars_map_state: Function fars_map_state

Description Usage Arguments Value Examples

View source: R/week2_exercise.R

Description

This function gets as input a state number (in USA) and a year. Its output is a map of this state with points located at the geographical location of motor crashes that happened in that state in that year. Note that invalid year (where no file exists for that year), or invalid state number will give an appropriate error.

Usage

1
fars_map_state(state.num, year)

Arguments

state.num

The state number in USA.

year

The year number

Value

This function returns a map of the specific state with all motor crash locations That happened in the specific year in that state. All data is taken from relevant file.

Examples

1
2
fars_map_state(1,2015)
fars_map_state(18,"2013")

Milcat/week2 documentation built on April 17, 2020, 12:03 a.m.