fars_read: Read data from a file into a tbl dataframe

Description Usage Arguments Value Examples

View source: R/fars_functions.R

Description

This function reads data from a specified file. This operation is based on the read_csv function from the readr package. It is useful for reading the most common types of flat file data, comma separated values and tab separated values.

Usage

1
fars_read(filename)

Arguments

filename

A character string which specifies path to a file. Files ending in .gz, .bz2, .xz, or .zip will be automatically uncompressed.

Value

This function return a tbl data frame (using the dplyr package). An error will be thrown if the specified file dosen't exist.

Examples

1
2
3
4
## Not run: 
fars_read("data/accident_2013.csv.bz2")

## End(Not run)

km20/farsP documentation built on May 22, 2019, 4:41 p.m.