eq_map: Map earthquake data to a leaflet tile

Description Usage Arguments Value Examples

View source: R/Map.R

Description

Map earthquake data to a leaflet tile

Usage

1

Arguments

df

A data.frame such as this obtainded from NOAA.

Value

A graph with markers for specified earthquaks and popups with info; location, magnitude and deaths.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
# load and clean data
file_path <- system.file("data", "dt.tsv", package = "PCR")
dt <- read_tsv(file_path) %>%
  eq_clean_date %>%
  eq_clean_location

# make graph
dt %>%
filter(COUNTRY == 'MEXICO' & year(date) >= 2000) %>%
  mutate(popup_text = eq_create_label(.)) %>%
  eq_map()

## End(Not run)

prathmeshchaudhari/PCR documentation built on May 3, 2019, 2:56 p.m.