searchable (version 0.3.3.1)

reverse.lookup: Perform a reverse lookup on searchables

Description

This function causes the pattern search to be performed against an object's values instead of its names

Usage

reverse.lookup(string)

Arguments

string
pattern for which to match against an objects values

reverse.lookup sets and toggles the logical attribute with name reverse.lookup. Actual implementation of the reverse lookup is performed in the Extract methods.

In order to

Value

  • a string object with the reversse.lookup attribute set.

reverse.lookup

When performing a reverse lookup, values (not names) are searched. The corresponding names are returned. NOTE: this is highly experimental and only works for atomic vectors. It is uncertain how this might be applied to recursive structures like lists.

See Also

The invert function in the hash package

Examples

Run this code
reverse.lookup("string")

Run the code above in your browser using DataLab