Learn R Programming

gsClusterDetect (version 1.0.0)

generate_heatmap: Generate heatmap of data

Description

Generate a ggplot heatmap of count information by date and location given a frame of count-by-location-and-date data.

Usage

generate_heatmap(heatmap_data, plot_type = c("ggplot", "plotly"), ...)

Value

a ggplot or plotly object

Arguments

heatmap_data

data frame generated by `generate_heatmap_data`

plot_type

string indicating either a "ggplot" or "plotly" result. If the requested backend is unavailable, the function warns and falls back to the other backend when available.

...

passed onto plotly

Examples

Run this code
hd <- generate_heatmap_data(example_count_data)
generate_heatmap(hd)
generate_heatmap(hd, plot_type = "plotly")

Run the code above in your browser using DataLab