plot_stratum_stacked_bar: Make condition time series stacked bar plot

View source: R/plot_stratum_stacked_bar.R

plot_stratum_stacked_barR Documentation

Make condition time series stacked bar plot

Description

Make condition time series stacked bar plot

Usage

plot_stratum_stacked_bar(
  x,
  region,
  fill_palette = "BrBG",
  var_y_name = "mean_wt_resid",
  var_x_name = "year",
  var_group_name = "stratum",
  fill_title = "Stratum",
  y_title = "Length-weight residual (ln(g))"
)

Arguments

x

Input data.frame

region

Region. AI, BS, or GOA. Character (1L).

var_y_name

Name of the y variable in the data.frame. Character (1L).

var_x_name

Name of the x (time variable). Character (1L).

var_group_name

Name of the variable to use for grouping (i.e., stratum). Character (1L).

fill_title

Name of the fill variable to use for plotting. Character (1L).

y_title

Y-axis title. Character (1L).

var_y_se_name

Name of the standard error for the y variable. Character (1L).

Value

A ggplot object of the time series

Examples

## Not run: 
# EBS strata stacked bar plot

names(EBS_INDICATOR$STRATUM)

plot_stratum_stacked_bar(x = EBS_INDICATOR$STRATUM,
region = "BS",
fill_palette = "BrBG",
var_y_name = "stratum_resid_mean",
var_x_name = "year",
var_group_name = "stratum",
fill_title = "Stratum",
y_title = "Length-weight residual (ln(g))")

## End(Not run)

afsc-gap-products/akfishcondition documentation built on June 11, 2025, 5:37 p.m.