plot_phases {ArchaeoPhases}R Documentation

Plot Phases

Description

Plots the characteristics of a group of events (phase).

Usage

## S4 method for signature 'PhasesMCMC,missing'
plot(
  x,
  calendar = getOption("ArchaeoPhases.calendar"),
  density = TRUE,
  range = TRUE,
  succession = NULL,
  level = 0.95,
  sort = TRUE,
  decreasing = TRUE,
  legend = TRUE,
  main = NULL,
  sub = NULL,
  ann = graphics::par("ann"),
  axes = TRUE,
  frame.plot = FALSE,
  panel.first = NULL,
  panel.last = NULL,
  col.density = "grey",
  col.range = "black",
  col.succession = c("#77AADD", "#EE8866"),
  ...
)

Arguments

x

A PhasesMCMC object.

calendar

A TimeScale object specifying the target calendar (see calendar()).

density

A logical scalar: should estimated density be plotted?

range

A logical scalar: should phase time range be plotted (see boundaries())?

succession

A character string specifying the additional time range to be displayed. It must be one of "hiatus" or "transition". If NULL (the default), no additional time ranges are displayed.

level

A length-one numeric vector giving the confidence level.

sort

A logical scalar: should the data be sorted?

decreasing

A logical scalar: should the sort order be decreasing? Only used if sort is TRUE.

legend

A logical scalar: should a legend be displayed?

main

A character string giving a main title for the plot.

sub

A character string giving a subtitle for the plot.

ann

A logical scalar: should the default annotation (title and x and y axis labels) appear on the plot?

axes

A logical scalar: should axes be drawn on the plot?

frame.plot

A logical scalar: should a box be drawn around the plot?

panel.first

An an expression to be evaluated after the plot axes are set up but before any plotting takes place. This can be useful for drawing background grids.

panel.last

An expression to be evaluated after plotting has taken place but before the axes, title and box are added.

col.density, col.range, col.succession

A specification for the plotting colors.

...

Extra parameters to be passed to stats::density().

Value

plot() is called it for its side-effects: it results in a graphic being displayed (invisibly returns x).

Author(s)

A. Philippe, M.-A. Vibet, T. S. Dye, N. Frerebeau

See Also

stats::density()

Other plot methods: plot_events

Examples

## Coerce to MCMC
eve <- as_events(mcmc_events, calendar = CE(), iteration = 1)

## Summary
summary(eve, calendar = CE())
summary(eve, calendar = BP())

## Plot events
plot(eve, calendar = CE(), interval = "credible", level = 0.68)
plot(eve, calendar = BP(), interval = "hdr", level = 0.68)
plot(eve[, 1], interval = "hdr")

## Compute phases
pha <- phases(eve, groups = list(B = c(2, 4), A = c(1, 3)))

## Summary
summary(pha, calendar = CE())
summary(pha, calendar = BP())

## Plot phases
plot(pha, calendar = BP())
plot(pha, succession = "hiatus")
plot(pha, succession = "transition")

[Package ArchaeoPhases version 2.0 Index]