eq_create_label: eq_create_label

Description Usage Arguments Value Examples

View source: R/earthquake.R

Description

A function to generate a custom popup box for a selected earthquake showing location, magnitude and total deaths.

Usage

1
eq_create_label(eq_data)

Arguments

eq_data

A data table containing NOAA Earthquake data

Value

An interactive map displaying earthquate location for a given country with custom popup.

Examples

1
2
3
4
5
library(dplyr)
eq_clean_data(eq_data_raw) %>%
  eq_location_clean() %>%
  dplyr::filter(COUNTRY == "MEXICO" & lubridate::year(date) >= 2000) %>%
  dplyr::mutate(popup_text = eq_create_label(.)) %>% eq_map(annot_col="popup_text")

Moonglum8/rEarthquake documentation built on July 17, 2020, 5:10 p.m.