eq_create_label: Create an earthquake label column

Description Usage Arguments Value Examples

View source: R/maps.R

Description

This function takes a dataframe (df) and returns a character vector of HTML column names. Note that the dataframe must have columns CLEAN_LOCATION_NAME, EQ_PRIMARY and DEATHS.

Usage

1

Arguments

df

The dataframe that we'll be using to create our annotation column.

Value

Returns a character vector of earthquake details that we can use for map annotations.

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
map2 <-load_data() %>%
  eq_clean_data() %>%
  dplyr::filter(COUNTRY == "MEXICO" & lubridate::year(date) >= 2000) %>%
  dplyr::mutate(popup_text = eq_create_label(.)) %>%
  eq_map(annot_col = "popup_text")
print(map2)

## End(Not run)

simongarisch/R-Capstone-NOAA documentation built on Dec. 23, 2017, 10:28 a.m.