Internal worker shared by the plotDiet() methods. It melts the diet array
into a data frame, restricts to meaningful size ranges, converts to a length
axis if requested and draws a stacked-area plot of prey proportions.
plot_diet(
params,
n,
diet,
species,
log_x,
log_y,
wlim,
llim,
size_axis,
return_data
)A mizer_plot (ggplot2) object, or the plotting data frame if
return_data = TRUE.
A MizerParams object.
Array of species abundances (species by size).
Array of diet proportions (predator by size by prey).
The predator species to be plotted.
Logical flags for log10 axes.
Numeric vectors of length two giving the weight and length limits.
Either "w" (weight) or "l" (length).
If TRUE, return the plotting data frame instead of the
plot.