new_pj | R Documentation |
Set the minimum and maximum x and y values of a pj object background its fill color, line color, line width, and edge padding (where plotting does not occur).
new_pj( xmin, xmax, ymin, ymax, w = 6.5, h = 4.5, pad = 0.01, pu = "in", fc = "grey95", lc = "black", lw = 1 )
xmin |
numeric scalar giving the minimum x-value for plotting objects in the background region. |
xmax |
numeric scalar giving the maximum x-value for plotting objects in the background region. |
ymin |
numeric scalar giving the minimum y-value for plotting objects in the background region. |
ymax |
numeric scalar giving the maximum y-value for plotting objects in the background region. |
w |
positive numeric scalar giving the width of the background in inches, centimeters, or millimeters. |
h |
positive numeric scalar giving the height of the background in inches, centimeters, or millimeters. |
pad |
proportion vector of length 1, 2, or 4 (see details section) with value no larger than 0.25. |
pu |
character scalar defining units in which |
fc |
character scalar fill color value. |
lc |
character scalar line color value. |
lw |
positive numeric scalar line width (default = 1). |
A pj object (a list of specific tibbles).
Edge padding can be achieved in three ways using the
pad
argument as shown in the following table:
edge | pad = p | pad = c(px, py)
| pad = c(pl, pr, pb, pt)
|
left | p \* min(w, h) | px \* w | pl \* w
|
right | p \* min(w, h) | px \* w | pr \* w
|
bottom | p \* min(w, h) | py \* h | pb \* h
|
top | p \* min(w, h) | py \* h | pt \* h
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.