What's a good term for an R value of length 1?
In R, the simplest kind of value is an "atomic" vector with a primitive type like
double, but it can have any length, so the term "atomic" is not what I want.
Here's an example: I often want to document my non-vectorized functions to indicate that, for a given argument, we're only interested in a single "value", i.e. something of length one. For instance, a function that sends data to a server would need an argument called
url, but I don't want to support sending an arbitrary number of HTTP calls to an arbitrary number of urls. I want
url to be an atomic character vector of length 1.
Is there a term for this already in use? Anything better than "of length 1"?
P.S. Note that R functions require these kinds of arguments all the time, like
anyNA(x, recursive = FALSE). It would be weird to provide a logical vector like
c(TRUE, FALSE, TRUE, FALSE) as a value for
recursive. But the docs don't seem to discuss this.