eq_clean_data: Clean downloaded data frame

Description Usage Arguments Value Examples

Description

This function reads an Earthquake dataset in a tab-delimited file to clean some of the variables. The function first checks whether the file to be read actually exists.If it does not exist, then it downloads from the NOOA website. Then, the function adds a date column created by uniting the year, month, day of each earthquake and converting it to the Date class. Finally, the function converts the LATITUDE and LONGITUDE columns to numeric class.

Usage

1
eq_clean_data(filename)

Arguments

filename

A character vector of the name of the tab-delimited file to be read.

Value

This function returns a clean data frame.

Examples

1
2
3
4
## Not run: 
eq_clean_data("signif.txt")

## End(Not run)

DanielAyllon/EarthQuakeAnalyzer documentation built on May 6, 2019, 1:23 p.m.