Skip to contents

Displays a scatter plot.

Usage

# S4 method for class 'LogRatio,missing'
plot(
  x,
  ...,
  factor = 1,
  amount = NULL,
  palette_color = palette_color_discrete(),
  palette_symbol = palette_shape(),
  xlab = NULL,
  ylab = NULL,
  main = NULL,
  sub = NULL,
  ann = graphics::par("ann"),
  axes = TRUE,
  frame.plot = axes,
  legend = list(x = "topright")
)

Arguments

x

A LogRatio object.

...

Further graphical parameters.

factor, amount

A length-one numeric vector specifying the amount of jitter (see jitter()).

palette_color

A palette function that when called with a single argument returns a character vector of colors (only used if x is grouped).

palette_symbol

A palette function that when called with a single argument returns a vector of symbols (only used if x is grouped).

xlab, ylab

A character vector giving the x and y axis labels.

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?

legend

A list of additional arguments to be passed to graphics::legend(); names of the list are used as argument names. If NULL, no legend is displayed.

Value

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

See also

Other plot methods: as_graph(), barplot(), hist(), pairs()

Author

N. Frerebeau

Examples

## Data from Day et al. 2011
data("kommos", package = "folio")
kommos <- remove_NA(kommos, margin = 1) # Remove cases with missing values
coda <- as_composition(kommos, groups = 1) # Coerce to compositional data

## Log ratio
clr <- transform_clr(coda)

## Use ceramic types for grouping
plot(clr)