symbology: Draws the symbols of a collection

View source: R/symbology.R

symbologyR Documentation

Draws the symbols of a collection

Description

Draws all the required symbols from a collection of them

Usage

symbology(
  collection,
  sym,
  x,
  y,
  xfac = 1,
  yfac = 1,
  xadj = 0,
  yadj = 0,
  col = NA,
  border = "black",
  density = NA,
  angle = 45,
  lty = par("lty"),
  lwd = par("lwd"),
  scol = border,
  slty = lty,
  slwd = lwd
)

Arguments

collection

a collection object (e.g. oufti)

sym

the name of the symbols in the collection

x, y

numeric vectors of coordinates where the object should be drawn.

xfac

the x size factor.

yfac

the y size factor.

xadj

value specifying the x adjustment of the drawing.

yadj

value specifying the y adjustment of the drawing.

col

the polygons background color. If density is specified with a positive value this gives the color of the shading lines.

border

the lines color.

density

the density of shading lines, in lines per inch. The default value of NULL means that no shading lines are drawn.

angle

the slope of shading lines, given as an angle in degrees (counter-clockwise)

lty, lwd

the border line type and width, see ?par for details.

scol, slty, slwd

the colour, type and width of the shading lines.

See Also

Similar functions: centresvg, framesvg and placesvg

Collections available in StratigrapheR: oufti99

Examples

# Create a data frame for all the required information ----

a <- data.frame(name = c("ammonite", "marcassite",
                         "nodule.point", "ammonite"),
                x = c(1,3,5,1),
                y = c(1,3,5,5),
                col = c(NA, "grey90",
                        "grey50", "grey90"))

# Draw them all in a single line of code ----

plot.new()
plot.window(xlim = c(0,6), ylim = c(0, 6))

axis(1)
axis(2, las = 1)

symbology(oufti99, a$name, a$x, a$y, col = a$col)


StratigrapheR documentation built on July 9, 2023, 6:02 p.m.