Animate net migration from calc_flux()
.
Usage
animate_flux(flux, bf, title = species(bf), ...)
Arguments
- flux
A flux object as created by calc_flux(format = "dataframe")
- bf
A BirdFlow object
- title
The plot title
- ...
Arguments passed on to
plot_flux
subset
A subset of the transitions in
flux
to plot, can be a logical vector of the same length as the number of transitions influx
; a numeric index of transitions influx
, or a subset of the transition names influx
.limits
Two numbers representing the range in flux values to display. Values outside of this range will be truncated to the range. With the default of
NULL
the entire range is plotted.dynamic_scale
If
TRUE
then the range of the data in each transition is mapped to the color palette. This makes it easier to see the variation within a single transition but results in an inconsistent scale among transitions.coast_linewidth
The line width used to plot the coast. Set to
NULL
to skip plotting the coastline.coast_color
The color used to plot the coastline, or
NULL
to skip plotting the coastline.gradient_colors
The colors palette used to represent the flux intensity.
value_label
The label for the flux values.
transform
A transformation to apply to the color scaling.
"identity"
, and"sqrt"
are recommended. If"log"
is used zeros will be replaced with 1/2 the smallest non-zero value prior to transforming. Legend will still reflect the original values. Passed toggplot2::scale_color_gradientn()
.
Value
A gganim
object