Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

new.name

Obtain a name for a new variable that is not already in use


Description

gamm works by transforming a GAMM into something that can be estimated by lme, but this involves creating new variables, the names of which should not clash with the names of other variables on which the model depends. This simple service routine checks a suggested name against a list of those in use, and if neccesary modifies it so that there is no clash.

Usage

new.name(proposed,old.names)

Arguments

proposed

a suggested name

old.names

An array of names that must not be duplicated

Value

A name that is not in old.names.

Author(s)

Simon N. Wood simon.wood@r-project.org

References

See Also

Examples

require(mgcv)
old <- c("a","tuba","is","tubby")
new.name("tubby",old)

mgcv

Mixed GAM Computation Vehicle with Automatic Smoothness Estimation

v1.8-35
GPL (>= 2)
Authors
Simon Wood <simon.wood@r-project.org>
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.