Calculate x and y coordinates of the midpoints of triangles tiled to cover a ternary plot.
TriangleCentres(resolution = 48L, direction = getOption("ternDirection", 1L))
The number of triangles whose base should lie on the longest axis of the triangle. Higher numbers will result in smaller subdivisions and smoother colour gradients, but at a computational cost.
(optional) Integer specifying the direction that the current ternary plot should point: 1, up; 2, right; 3, down; 4, left.
TriangleCentres() returns a matrix with three named rows:
x x coordinates of triangle midpoints;
y y coordinates of triangle midpoints;
0 for upwards-pointing triangles,
1 for downwards-pointing.