Convert user-specified ternary coordinates into X and Y coordinates
Source:R/Holdridge.R, R/TernaryPlot.R
CoordinatesToXY.RdAccepts various formats of input data; extracts ternary coordinates and converts to X and Y coordinates.
Arguments
- pet, prec
Numeric vectors giving potential evapotranspiration ratio and annual precipitation (in mm).
- coordinates
A list, matrix, data.frame or vector in which each element (or row) specifies the three coordinates of a point in ternary space. Each element (or row) will be rescaled such that its entries sum to 100.
Value
CoordinatesToXY() returns an array of two rows, corresponding to
the X and Y coordinates of coordinates.