Automatically projects regional INKAR data onto administrative boundaries of Germany using
the geodata and sf packages. Supports Bund (BND), Bundeslaender (BLD), Kreise (KRE),
and Gemeinden (GEM) levels. Alternatively, a custom sf geometry can be provided.
Arguments
- data
A data frame returned by
get_inkar_data().- variable
Character. For wide-format data with multiple indicators, specify which indicator column to plot.
- year
Integer/Character. If the data contains multiple years, specify which year to plot. If NULL and multiple years exist, the most recent year is plotted.
- mode
Character. "light" (default) or "dark" theme.
- highlight
Character vector. Region names (partial match) to highlight; all other regions are shown at reduced opacity.
- breaks
Character. Color scale break method:
"equal"(default) or"quantile"for quantile-based color breaks.- title
Character. Custom plot title. Defaults to the indicator name.
- geom
Optional
sfobject (spatial data frame) to use for plotting. If supplied, GADM geometries are not downloaded, and the data is merged directly with this object.