Builds a Leaflet map of H3 fishing effort with one layer per year, toggled via a radio-button year control. Hexagon colour reflects a log-scaled effort metric. A basemap switcher (Dark / Light / Satellite) is provided via a custom control in the top-right corner.
Usage
plot_effort_map(effort, metric = c("fishing_hours", "n_trips"))Arguments
- effort
A data frame with columns
h3_index,year,fishing_hours,unique_trips(as returned byaggregate_pds_effort()).- metric
Column to colour hexagons by:
"fishing_hours"(default) or"n_trips".
Details
The function accepts the output of aggregate_pds_effort() (which includes
a year column) and aggregates effort to the H3 cell level within each year
before building the map layers. An all-time view can be approximated by
first collapsing the data across years:
