fars_summarize_years: Summarises the number of fatalities per month for a given...

Description Usage Arguments Value Examples

View source: R/farsfunctions.R

Description

This function reads in a year or a list of years and creates a tibble summarising the number of fatalities per month as rows and year as columns from a standard NHFTS FARS /hrefhttps://www.nhtsa.gov/research-data/fatality-analysis-reporting-system-fars file containing that year in the filename.

Usage

1

Arguments

years

A string of length 4 giving the year, or list of years, in the NHFTS FARS filename from which the month and year attributes will be summarised.

Value

A tibble containing the number of fatalities per month for each input year.

Examples

1
2
fars_summarize_years(2013)
fars_summarize_years(c(2013, 2014, 2015))

csgbloom/farspackage documentation built on May 20, 2020, 10:15 a.m.