createTernaryGeometry: Creates a ternaryGeometry object: ternary plot geometry...

Description Usage Arguments Details Value Examples

Description

Creates a ternaryGeometry object: ternary plot geometry definition.

Usage

1
2
createTernaryGeometry(tlrAngles = c(60, 60, 60), blrClock = rep(TRUE, 3),
  fracSum = 100, ...)

Arguments

tlrAngles

Vector of numeric. Top, left and right angle (in degrees) of the ternary diagram. Must sum to 180 degrees.

blrClock

Vector of logical value. Bottom, left and right axis directions. Set to TRUE if the axis is clockwise, and to FALSE if the axis is counter-clockwise.

fracSum

Single numeric value. Sum of the three fractions. Must be 1 (if a fraction) or 100 (if a percentage).

...

Additional parameters passed to ternaryCheck

Details

In this package, ternary plots geometries are defined by the 3 triangle's angles (top, left, right), and by the sum of the 3 fractions it represents (1 if a fraction, and 100 if a percentage).

Value

Return a list of ternaryGeometry-class (S3). A 2nd class is added that depends on blrClock, and is formed after the pattern "geo_[blrClockCode]", where [blrClockCode] can be "TTT", "FFF", "FTX" or "TXF".

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
library( "ternaryplot" ) 


## Default geometry
tg <- createTernaryGeometry()
tg

## Custom geometry
tg <- createTernaryGeometry( 
    "fracSum"   = 1, 
    "blrClock"  = rep( FALSE, 3 ), 
    "tlrAngles" = c( 45, 45, 90 ) ) 
tg 

ternaryplot documentation built on May 2, 2019, 6:11 p.m.