fars_read: Reads data from a file

Description Usage Arguments Value Examples

Description

This function first checks if the file exists. If it does, it reads the data and converts it into a tibble. If the file does not exist, it will throw an error. Note that this filename can be conveniently created using make_filename function included in this package.

Usage

1
fars_read(filename)

Arguments

filename

Name of the file(character string) from which to read the data.

Value

This function returns a tibble contianing the data.

Examples

1
2
3
file_2013 <- make_filename(2013)
file_2013 <- paste0(system.file("extdata", package = "fars"), "/",file_2013)
fars_read(file_2013)

pchhina/fars documentation built on May 5, 2019, 3:54 p.m.