fars_read_years: Function 'fars_read_years' take as an argument a four-digit...

Description Usage Arguments Value Examples

View source: R/fars_functions.R

Description

Function fars_read_years take as an argument a four-digit year and makes a dataset containing columns month and year of an accident that occurred

Usage

1

Arguments

years

Four-digit year, as integer or as a string (i.e. 2001, "2001").

Value

Data frame with columns:

MONTH

a value between 1 and 12, 1 for January, 12 for December

year

four-digit value for a year

If the requested year input is not present in the data, the function returns a warning: "invalid year".

Examples

1
2
3
4
5
6
## Not run: 
fars_read_years(2013)
fars_read_years("2013")
fars_read_years(c(2013,2014,2016))

## End(Not run)

kurowska/fars documentation built on May 20, 2019, 7:06 p.m.