x, the row that has the same combination in tableMatch, for each combination of a set of columns in x,
the rows that has the same combination in table.
The argument multiples.allow controls what happens when there are
multple matches in table of a combination in x.
fac.match(x, table, col.names, nomatch = NA_integer_, multiples.allow = FALSE)an R object, normally a data.frame, possibly a
matrix.
an R object, normally a data.frame, possibly a
matrix.
A character vector giving the columns in x
and table that are to be matched.
The value to be returned in the case when no match is found. Note that it is coerced to integer.
A logical indicating whether multiple matches of a
combination in x to those in table is allowed.
If multiples.allow is FALSE, an error is generated.
If multiples.allow is TRUE, the first occuence in
table is matched. This function can be viewed as a
generalization to multiple vectors of the match
function that applies to single vectors.
A vector of length equal to x that gives the
rows in table that match the combinations of
col.names in x. The order of the rows is the same as
the order of the combintions in x. The value returned if a combination is
unmatched is specified in the nomatch argument.