Description Usage Arguments Details Value Examples
Generate maps based on NOAA earthquake data
1 |
data |
NOAA earthquake data in a clean dataframe (after a call to |
annot_col |
The column that will be taken for anotaion of the earthquakes |
The function maps the epicenters (LATITUDE/LONGITUDE) and annotates each point with a pop up window containing annotation data stored in a column of the data frame. The user should be able to choose which column is used for the annotation in the pop-up with a function argument named annot_col. Each earthquake should be shown with a circle, and the radius of the circle should be proportional to the earthquake's magnitude (EQ_PRIMARY).
The leaflet map with the earthquake data
1 2 3 4 5 | library(dplyr)
library(lubridate)
earthquake_data %>%
filter(COUNTRY == "MEXICO" & year(DATE) >= 2000) %>%
eq_map(annot_col = "DATE")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.