build_fig_back: Create a R markdown backbone for a figure call.

View source: R/markdown_tools.R

build_fig_backR Documentation

Create a R markdown backbone for a figure call.

Description

Builds a character with the R code chunk for the given figure.

Usage

build_fig_back(
  figure_call,
  ref_name = "figure",
  caption = "figure",
  figure_w = 5,
  figure_h = 7,
  legend = TRUE,
  legend_text = "<<legend>>"
)

Arguments

figure_call

call to a figure object.

ref_name

name of the figure chunk in the R markdown output.

caption

figure caption.

figure_w

figure width in inches or a call to a function returning a numeric provided as a character.

figure_h

figure height in inches or a call to a function returning a numeric provided as a character.

legend

logical, should a text with the figure reference in bold be included below the figure chunk?

legend_text

detailed legend text.

Value

a string with the figure object R markdown chunk.


PiotrTymoszuk/figur documentation built on July 16, 2024, 1:15 a.m.