Description Usage Arguments Details Value See Also Examples

The function returns the labels of the terms of the model Note. The terms are not identical to the coefficients.

1 | ```
coef2term(model, ef)
``` |

`model` |
a model object. |

`ef` |
a character vector of coefficient labels. |

`model`

is an object returned by a model fitting
function (e.g., `lm`

, `aov`

).

The character string passed to `ef`

must not include the
intercept (`"(Intercept)"`

).
All non-intercept labels of any order are allowed.

a character vector of term labels (one element for each
element in `ef`

).

`term2coef`

for the inverse function.

1 2 3 4 5 6 7 8 9 10 11 12 | ```
require(utils)
data(iris)
fit <- lm(Sepal.Length ~ poly(Sepal.Width, 3), data = iris)
summary(fit)
coef2term(fit, "poly(Sepal.Width, 3)2")
data(warpbreaks)
fit2 <- lm(breaks ~ wool * tension, data = warpbreaks)
summary(fit2)
coef2term(fit2, c("woolB", "tensionH"))
coef2term(fit2, c("woolB:tensionM"))
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.