eq_map: Interactive map visualization for earthquakes

Description Usage Arguments Value Examples

View source: R/NOAAviz.R

Description

eq_map maps the epicenters (LATITUDE/LONGITUDE) with a radius proportional to the earthquake's magnitude (EQ_PRIMARY) "and annotates each point with in 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." (Mastering Software Development in R Capstone, Week 3)

Usage

1
eq_map(eq_df, annot_col = NA)

Arguments

eq_df

a cleaned earthquake data frame to map

annot_col

the string name of a column to use for annotation of the earthquake locations in eq_df (optional)

Value

a leaflet map object

Examples

1
2
3
4
5
6
7
## Not run: 
    clean_NOAA_data %>%
         dplyr::filter(COUNTRY == "JAPAN" &
                       lubridate::year(DATE) >= 2000) %>%
         eq_map(annot_col = "DATE")

## End(Not run)

jdallmann/NOAAviz documentation built on Nov. 4, 2019, 2:35 p.m.