View source: R/fars_functions.R
fars_read | R Documentation |
read FARS data (US National Highway Traffic Safety Administration's Fatality Analysis Reporting System)from file
fars_read(filename)
filename |
, name of file to be read |
it is necessary to download the fars files before, this functions read the files from the working directory, if not an error will be thrown Throws an error if wrong file name is provided
a data.frame with the data of file
library(dplyr)
library(readr)
library(tidyr)
f13path<-system.file("inst", "extdata", "accident_2013.csv.bz2")
file.copy(from=c(f13path),to=getwd())
fars_read('accident_2013.csv.bz2')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.