This generics are used to check whether a key exists in a given
hashset
or hashmap
.
has_key(x, key) x %has_key% key # S3 method for r2r_hashmap has_key(x, key) # S3 method for r2r_hashset has_key(x, key)
x | an |
---|---|
key | an arbitrary R object. Key to be checked for existence in the hash table. |
TRUE
or FALSE
.
Valerio Gherardi
#> [1] TRUEm %has_key% "b"#> [1] TRUE