TITAN2 (version 2.4)

plot_taxa_ridges: Taxon change point ridge plots

Description

Taxon change point ridge plots

Usage

plot_taxa_ridges(
  titan.out,
  z1 = TRUE,
  z2 = TRUE,
  z1_fill_low = "lightblue",
  z1_fill_high = "black",
  z2_fill_low = "pink",
  z2_fill_high = "red",
  pur.cut = titan.out$arguments[[7]],
  rel.cut = titan.out$arguments[[8]],
  xlabel = "Environmental Gradient",
  n_ytaxa = 90,
  printspp = FALSE,
  grid = TRUE,
  trans = "identity",
  xaxis = !grid,
  xlim,
  bw,
  ...,
  axis.text.x,
  axis.text.y,
  axis.title.x,
  axis.title.y
)

Arguments

titan.out

A TITAN output object.

z1

A logical specifying whether decreasing taxa should be plotted.

z2

A logical specifying whether increasing taxa should be plotted.

z1_fill_low, z1_fill_high, z2_fill_low, z2_fill_high

Respective fill colors passed to scale_fill_gradient()

pur.cut

pur.cut

rel.cut

rel.cut

xlabel

A character string for the x axis label.

n_ytaxa

The maximum number of taxa to be plotted.

printspp

A logical specifying whether the sppmax table should be printed.

grid

The grid argument of theme_ridges(). Setting this to FALSE removes horizontal lines from the plot, see examples.

trans

a scale transformation to be applied to the x-axis through ggplot2. e.g. "log10" or "sqrt".

xaxis

Logical; should the x-axis be plotted?

xlim

x axis limits, e.g. xlim = c(0,10).

bw

The bandwidth of used in the kernel density estimate; see density().

...

Arguments to pass to geom_density_ridges()

axis.text.x, axis.text.y, axis.title.x, axis.title.y

Font sizes of respective axis text. Passed as the size argument to the ggplot2 thematic elements of the same name. Defaults to current default ggplot2 theme.

Value

A plot of decreasing and/or increasing taxon-specific change points along the environmental gradient.

References

Baker, ME and RS King. 2010. A new method for detecting and interpreting biodiversity and ecological community thresholds. Methods in Ecology and Evolution 1(1): 25:37.

King, RS and ME Baker 2010. Considerations for identifying and interpreting ecological community thresholds. Journal of the North American Benthological Association 29(3):998-1008.

See Also

plot_sumz(), plot_cps()

Examples

Run this code
# NOT RUN {
data(glades.titan)


# basic usage
plot_taxa_ridges(glades.titan)


# }
# NOT RUN {
 reduce R CMD check time

# manipulating the x axis thematic components
plot_taxa_ridges(glades.titan, grid = FALSE)
plot_taxa_ridges(glades.titan, xaxis = TRUE)


# applying scale transformations
plot_taxa_ridges(glades.titan, trans = "log10", xlim = c(1,150))


# removing z2
plot_taxa_ridges(glades.titan, z2 = FALSE, trans = "sqrt", xlim = c(0, 150))


# more styling
plot_taxa_ridges(glades.titan,
  axis.text.x = 12,
  axis.text.y = 4,
  axis.title.x = 14,
  xlabel = expression(paste("Surface water total phosphorus ("*mu*"g/l)"))
)

# }
# NOT RUN {

# }

Run the code above in your browser using DataLab