powered by
Create unique names within a list, a data.frame, or an environment
tempname(where = globalenv(), n = 1, prefix = ".temp", inherits = TRUE)
A chracter vector, list or an environment
An integar that specifies length of the output
A character vector that specifies prefix for new name
Should the name unique also in the enclosing frames of the environment?
tempname(c("temp1", "temp3"), 4) tempname(globalenv()) tempname(data.frame(temp = 1), n = 3)
Run the code above in your browser using DataLab