Function to add a grid to an existing (barycentric) plot.

1 2 |

`x` |
Values along which to draw grid lines for first dimension
(or all dimensions if |

`y` |
Grid lines for second dimension. |

`z` |
Grid lines for third dimension. |

`lty` |
Line type (see |

`col` |
Line colour (see |

`...` |
Further graphical parameters passed to |

Grid lines illustrate the set of points for which one of the dimensions is held constant; e.g. horizontal lines contain all points with a certain value y for the second dimension, connecting the two extreme points (0,y,1-y) and (1-y,y,0).

Grids may be designed more flexible than with `triplot`

's `grid`

option.

Christian RĂ¶ver, roever@statistik.tu-dortmund.de

`triplot`

, `trilines`

, `triframe`

, `centerlines`

1 2 3 4 5 6 7 8 9 10 11 12 | ```
triplot(grid = FALSE)
trigrid(c(1/3, 0.5)) # same grid for all 3 dimensions
triplot(grid = c(1/3, 0.5)) # (same effect)
triplot(grid = FALSE)
# different grids for all dimensions:
trigrid(x = 1/3, y = 0.5, z = seq(0.2, 0.8, by=0.2))
triplot(grid = FALSE)
# grid for third dimension only:
trigrid(x = NA, y = NA, z = c(0.1, 0.2, 0.4, 0.8))
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.