eq_map: Create Map

Description Usage Arguments Value Examples

Description

This function takes a filted dataframe object and create a map of the earthquakes with a popup label describing the earthquakes.

Usage

1
eq_map(filtered_data, annot_col = "DATE")

Arguments

filtered_data

A subset dataframe from the eq_clean_data function for the country and period of interest

annot_col

A character string representing the column name from the dataset from which the label of earthquake should be obtained

Value

A leaflet object representing the map of earthquake points

Examples

1
2
3
4
5
6
7
## Not run: readr::read_delim("./inst/extdata/dataset.txt", delim = "\t") %>% 
  eq_clean_data() %>% 
  eq_location_clean() %>%
  filter(COUNTRY == "MEXICO" & lubridate::year(DATE) >= 2000) %>% 
  mutate(popup_text = eq_create_label(.)) %>% 
  eq_map(annot_col = "popup_text")
## End(Not run)

elyminator91/MasteringSoftwareDevelopmentCapstone documentation built on May 20, 2019, 9:59 a.m.