fars_read_years: Year and month the accidents happened.

Description Usage Arguments Value Examples

Description

The function takes the list of years that we want to know about the accident, find the files that record those accidents by the year and returning the columns of the months and the year. An error "invalid year: <inputed year>" will be printed if the data of the year we inputed is not availabe.

Usage

1

Arguments

years

A list of years (in integer) that we want to read the data about.

Value

A data frame with 2 columns specifying the Month and the year for each accidents by the years that we put in the list.

Examples

1
2
fars_read_years(c(2013, 2014))
fars_read_years(2013)

RushdSowell/farsForCoursera documentation built on May 20, 2019, 2:57 p.m.