Skip to contents

has.key returns a logical vector as long as keys, indicating which keys are defined on the hash.

Usage

has.key(key, hash, ...)

Arguments

key

A vector whose entries will be coerced to valid keys.

hash

A hash object.

...

arguments passed to further functions

Details

None.

Value

logical

A logical vector of length key indicating whether the key is defined in the hash. has.key also accepts ... to be passed to underlying sapply

Author

Christopher Brown

See also

See also hash

Examples


    h <- hash( letters, 1:26 )
    all( has.key( letters, h ) ) # TRUE
#> [1] TRUE