eq_create_label: Map Annotations

Description Usage Arguments Details Value Examples

Description

Create Annotation Column for use in eq_map

Usage

1

Arguments

data

dataframe containing the columns LOCATION_NAME, EQ_PRIMARY and DEATHS

Details

This function creates a text annotation column in html with the format VariableName: Value for Location, Magnitude and Total Deaths of each earthquake in seperate rows. Where the data is missing the corresponding row will be omitted. Can be used for example with the dplyr::mutate function (see examples).

Value

Label Character vector in html format

Examples

1
2
3
4
5
6
## Not run: 
readr::read_delim("results.tsv", delim = "\t") %>% eq_clean_data() %>%
 dplyr::filter(COUNTRY == "MEXICO" & lubridate::year(DATE) >= 2000) %>%
dplyr::mutate(popup_text = eq_create_label(.)) %>% eq_map(annot_col = "popup_text")

## End(Not run)

ckoopmann/EQVisualisation documentation built on May 29, 2019, 2:07 p.m.