Extract a figure or table's caption and alternative text for usage when generating a figure or table. Typically used before satf::export_rda().

extract_caps_alttext(topic_label = NULL, fig_or_table = NULL, dir = getwd())

Arguments

topic_label

A string that describes a figure or table's label. These labels are found in the "label" column of the "captions_alt_text.csv" file and are used to link the figure or table with its caption/alt text.

fig_or_table

A string describing whether the plot is a figure or table.

dir

The directory containing the "captions_alt_text.csv" file.

Value

A figure's caption and alternative text, in a list, or a table's caption.

Examples

if (FALSE) { # \dontrun{
extract_caps_alttext(topic_label = "biomass",
                    fig_or_table = "figure",
                    dir = here::here())

extract_caps_alttext(topic_label = "bnc",
                    fig_or_table = "table",
                    dir = getwd())
} # }