Fast match() function

Package providing a fast match() replacement for cases that require repeated look-ups. It is slightly faster that R's built-in match() function on first match against a table, but extremely fast on any subsequent lookup as it keeps the hash table in memory.


0.1-4 2012-01-12 o some R functions (such as subset assignment like x[1] <- 2) can create a new object (with possibly modified content) and copy all attributes including the hash cache. If the original object was used as a table in fmatch(), the hash cache will be copied into the modified object and thus its cache will be possibly out of sync with the object. fmatch() will now identify such cases and discard the hash to prevent errorneous results.

0.1-3 2011-12-21 o match() coerces POSIXlt objects into characters, but so far fmatch() performed the match on the actual objects. Now fmatch() coerces POSIXlt object into characters just like match(), but note that you will lose the ability to perform fast lookups if the table is a POSIXlt object -- please use POSIXct objects (much more efficient) or use as.character() on the POSIXlt object to create a table that you want to re-use.

0.1-2 2011-09-14 o bugfix: nomatch was ignored in the fastmatch implementation (thanks to Enrico Schumann for reporting)

0.1-1 2010-12-23 o minor cleanups

0.1-0 2010-12-23 o initial release

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


1.1-0 by Simon Urbanek, 24 days ago

Browse source code at

Authors: Simon Urbanek <>

Documentation:   PDF Manual  

GPL-2 license

Imported by RSNPset, ffbase, icd9, phangorn, quanteda.

Suggested by combiter, data.table.

See at CRAN