Description Usage Arguments Value See Also Examples
plot lines and symbols
1 2 3 4 5 |
x |
coordinates |
y |
coordinates |
size |
unit vector for the symbols |
pch |
vector of symbol types |
space |
numeric scaling factor for the exclusion zone |
only.lines |
logical: should only split lines be returned? |
arrow |
arrow passed to grid.segments |
gp |
gpar() object for the symbols |
name |
grob name |
default.units |
default units |
vp |
viewport |
a grob
Other grob userlevel: arcTextGrob
,
borderGrob
, colorstripGrob
,
ebimageGrob
, ellipseGrob
,
interleaven
, ngonGrob
,
patternGrob
, pixmapGrob
,
rpatternGrob
, stextGrob
,
tableGrob
, virtualGrob
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | set.seed(1234)
grid.barbed(name="test")
grid.edit("test", gp=gpar(fill="blue", lwd=3))
grid.edit("test::points", pch=22)
grid.newpage()
g <-
barbedGrob(size=unit(1:5, "char"), only=FALSE,
gp=gpar(col="red", lex=3, fill="blue", alpha=0.5, pch=3))
pushViewport(vp=viewport(width=1, height=1))
grid.rect(gp=gpar(fill="thistle2"))
grid.grill(gp=gpar(col="lavenderblush1", lwd=3, lty=3))
grid.draw(g)
x <- c(0.2, 0.7)
y <- x
dev.new(width=3, height=7)
grid.newpage()
g <-
barbedGrob(x, y, size=unit(c(2, 10), "mm"))
pushViewport(vp=viewport(width=1, height=1))
grid.draw(g)
grid.points(x, y, pch=3)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.