Description Usage Arguments Details Value Examples
eq_location_clean
takes a data frame of NOAA earthquake data and cleans
the LOCATION_NAME
field.
1 |
data |
A data frame of NOAA significant earthquake data, similar to what
can be loaded with |
This function cleans the LOCATION_NAME
observation in a NOAA
Significant Earthquakes data set. It removes the country name (of form
COUNTRY:
) from the LOCATION_NAME
data (unless the country is
the only name present in that field), and converts the remainder of the field
to Title Case. This will make the location name easier to read when plotting
and mapping.
A tbl_df
with the same supplied data, but with the
LOCATION_NAME
variable cleaned up to remove the country name that is
supplied in the COUNTRY
variable (unless the country name is the
only word in the LOCATION_NAME
observation), and convert
the remainder of the words in LOCATION_NAME
to Title Case.
1 2 3 | data(quakes)
quakes_loc_clean <- eq_location_clean(quakes)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.