add_ends | R Documentation |
An ends look is an end mark at the start, midpoint, and/or end of a line segment. End marks can be line-based arrows, triangle-based arrows, circles, diamonds, and squares.
add_ends( pj, segs = "a", ends = "e", mark = ">", size = 1, fc = "white", fa = 0.5, lc = "black", la = 0.5, lw = 1, shape = ".", name = "." )
pj |
an object of class |
mark |
character scalar giving the type of end mark to plot. |
size |
positive numeric vector indicating symbol size relative to the default (thus 1 indicates default sized, 1/2 indicates half sized, and 2 indicates double sized). For characters as marks, 1 indicates point size 10. |
fc |
|
fa |
|
lc |
|
la |
|
lw |
|
shape |
character scalar indicating the type of shape to which the look will be applied. |
loc |
character scalar giving the location of end marks on line
segments. |
which |
character scalar indicating which segments in a series of x-y
pairs should be given end marks. |
pj
with the addition of the end-mark look applied to the
specified shape.
Intervals can be validly
described using a number of patterns of argument properties as follows,
where base
indicates that the argument set (loc, which, size)
have all been supplied, line
indicates that the argument set
(lc, la, lw)
have all been supplied, and fill
indicates that
the argument set (fc, fa)
have both been supplied.
base + mark = ">" + line
line-based arrowheads as end mark.
base + mark = "t" + line
empty triangle-based arrowheads as end mark.
base + mark = "t" + fill
solid triangle-based arrowheads as end mark.
base + mark = "t" + line + fill
filled and outlined triangle-based arrowheads as end mark.
base + mark = "c" + line
empty circle as end mark.
base + mark = "c" + fill
solid circle as end mark.
base + mark = "c" + line + fill
filled and outlined circle as end mark.
base + mark = "d" + line
empty diamond as end mark.
base + mark = "d" + fill
solid diamond as end mark.
base + mark = "d" + line + fill
filled and outlined diamond as end mark.
base + mark = "s" + line
empty square as end mark.
base + mark = "s" + fill
solid square as end mark.
base + mark = "s" + line + fill
filled and outlined square as end mark.
The arguments mark
, size
,
lc
, la
, lw
, fc
, and/or fa
are recycled
with the number of segments between x-y pairs of the shape to which the
end-mark look is applied.
Other add_look:
add_ci()
,
add_fills()
,
add_glyphs()
,
add_labels()
,
add_lines()
,
add_marks()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.