This is a test package to implement an R package building process based on devtools, Travis CI (continuous integration) and testthat unit testing.

The package implements data analysis functions to be applied to accident statistics from "Factors Behind Traffic Fatalities on our Roads" data files.

Functions

The package contains the following functions:

  1. fars_read
  2. make_filename
  3. fars_read_years
  4. fars_summarize_years
  5. fars_map_state

fars_read

This reads a (possibly compressed) CSV data file and returns a data frame. This function should be used to load the FARS data files.

make_filename

This constructs a file name for a given year.

fars_read_years

Reads and combines data for multiple years into a list of data frames.

fars_summarize_years

Summarize data read for multiple years by number of accidents per month.

fars_map_state

Creates a map for the location of accidents within a state for a given year.



tynesjo/fars_functions_tst documentation built on May 3, 2019, 2:03 p.m.