knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

This package focuses on Fatality Analysis Reporting System (FARS) available from US National Highway Traffic Safety Administration. This system is a nationwide census providing the American public yearly data regarding fatal injuries suffered in motor vehicle traffic crashes. The purpose of the package FARfunctions is to provide functions to analyze some aspects of the data.

Example Usage

For example, the package can simply read the data for further custom analysis by the user. It also provides the possibility of compiling the accidents according to the months when these occurred. Finally, it provides a rudimentary map of where within a particular state these accidents occurred.

# reading the data
data <- fars_read("accident_2013.csv.bz2")

# inspect what the data looks like
head(data)

The user may be interested in exploring the association between particular sets of variables associated with particular accidents.

Next, we can show how to compile accidents according to their month of occurrence.

fars_summarize_years(c(2014, 2015))

Another application of the package is to plot the accidents onto a map of a

fars_map_state(6, 2014)


SergeyPry/FARfunctions documentation built on May 29, 2019, 5:57 p.m.