The R Project SVN R

Rev

Rev 24855 | Rev 45287 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 24855 Rev 25360
Line 4... Line 4...
4
\description{
4
\description{
5
  Makes the elements of a character vector unique by
5
  Makes the elements of a character vector unique by
6
  appending sequence numbers to duplicates.
6
  appending sequence numbers to duplicates.
7
}
7
}
8
\usage{
8
\usage{
9
make.unique(names, sep=".")
9
make.unique(names, sep = ".")
10
}
10
}
11
\arguments{
11
\arguments{
12
  \item{names}{a character vector}
12
  \item{names}{a character vector}
13
  \item{sep}{a character string used to separate a duplicate name from
13
  \item{sep}{a character string used to separate a duplicate name from
14
    its sequence number.}
14
    its sequence number.}
15
}
15
}
16
\value{
16
\value{
17
  a character vector of same length as \code{names} with duplicates changed.
17
  A character vector of same length as \code{names} with duplicates changed.
18
}
18
}
19
\details{
19
\details{
20
  The algorithm used by \code{make.unique} has the property that
20
  The algorithm used by \code{make.unique} has the property that
21
  \code{make.unique(c(A, B)) == make.unique(c(make.unique(A), B))}.
21
  \code{make.unique(c(A, B)) == make.unique(c(make.unique(A), B))}.
22
 
22