L() and ll() draw straight lines,
H() and hh() draw horizontal lines, and
V() and vv() draw vertical lines.
Usage
L(
x,
y = NULL,
...,
sep = getOption("dee.sep", ","),
origin_at_bottom = getOption("dee.origin_at_bottom", FALSE),
height = getOption("dee.height", NULL),
digits = getOption("dee.digits", Inf)
)
ll(
x,
y = NULL,
...,
sep = getOption("dee.sep", ","),
origin_at_bottom = getOption("dee.origin_at_bottom", FALSE),
height = getOption("dee.height", NULL),
digits = getOption("dee.digits", Inf)
)
LZ(...)
lz(...)
H(x, ..., digits = getOption("dee.digits", Inf))
hh(x, ..., digits = getOption("dee.digits", Inf))
HZ(...)
hz(...)
V(
y,
...,
origin_at_bottom = getOption("dee.origin_at_bottom", FALSE),
height = getOption("dee.height", NULL),
digits = getOption("dee.digits", Inf)
)
vv(
y,
...,
origin_at_bottom = getOption("dee.origin_at_bottom", FALSE),
height = getOption("dee.height", NULL),
digits = getOption("dee.digits", Inf)
)
VZ(...)
vz(...)Arguments
- x
If
yisNULLwill be coerced byaffiner::as_coord2d(). Else a numeric vector.- y
Either
NULLor a numeric vector.- ...
Passed to related function.
- sep
Either
","or" ".- origin_at_bottom, height
If
origin_at_bottomisTRUEtheny(and anyy1andy2) coordinates is transformed byheight - yfor absolute coordinates and-yfor relative coordinates.- digits
xandy(and anyx1,y1,x2,y2) will be transformed byround(, digits). AnInf(default) means no rounding.
Value
A dee() object.
Examples
M(1, 1) + L(2, 2) + Z()
#> <dee[1]>
#> M 1,1 L 2,2 Z
M(1, 1) + ll(1, 1) + zz()
#> <dee[1]>
#> M 1,1 l 1,1 z
d <- M(1,1) + L(5,8) + H(8) + V(3) + Z()
if (requireNamespace("omsvg", quietly = TRUE) &&
requireNamespace("nanosvgr", quietly = TRUE)) {
plot(d, height = 10, width = 10,
fill = "red", stroke = "black", stroke_width = 4)
}