Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

coord_tern

Ternary Coordinate System


Description

coord_tern is a function which creates a transformation mechanism between the ternary system, and, the cartesian system. It inherits from the fixed coordinate system, employing fixed ratio between x and y axes once transformed.

Usage

coord_tern(Tlim = NULL, Llim = NULL, Rlim = NULL, expand = TRUE)

Arguments

Tlim

the range of T in the ternary space

Llim

the range of L in the ternary space

Rlim

the range of R in the ternary space

expand

If TRUE, the default, adds a small expansion factor to the limits to ensure that data and axes don't overlap. If FALSE, limits are taken exactly from the data or xlim/ylim.

Value

coord_tern returns a CoordTern ggproto

Aesthetics (Required in Each Layer)

coord_ternunderstands the following aesthetics (required aesthetics are in bold):

  • x

  • y

  • z

Abovementioned limitations include the types of geometries which can be used (ie approved geometries), or modifications to required aesthetic mappings. One such essential patch is, for approved geometries previously requiring x and y coordinates, now require an additional z coordinate, and, geom_segment goes one step further in that it requires both an additional z and zend coordinate mappings.

In essence, the required aesthetics are the product between what is required of each 'layer' and what is required of the 'coordinate system'.

Author(s)

Nicholas Hamilton


ggtern

An Extension to 'ggplot2', for the Creation of Ternary Diagrams

v3.3.0
GPL-2 | file LICENSE
Authors
Nicholas Hamilton [aut, cre]
Initial release
2020-04-9

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.