make_filename: Format a valid filename given a year

Description Usage Arguments Value Note Examples

View source: R/fars_functions.R

Description

This is a function that reads a given filename, given by the filename argument into R using the read_csv function from the readr packages and then returning the read in table as a tbl_df object from the dplyr package.

Usage

1

Arguments

year

A character string or integer giving the year to use to format the filename. This parameter will be coerced to an integer in the function.

Value

This function returns a character string of a filename corresponding to the given year

Note

This function is called by the fars_read_years function and not usually called on its own. Hence not exported.

Examples

1
## Not run: make_filename(2013)

milandv/courserafars documentation built on March 19, 2018, 3:12 a.m.