Hash an object
hash()
hashes an arbitrary R object.
The generated hash is guaranteed to be reproducible across platforms, but not across R versions.
hash(x)
x |
An object. |
hash()
uses the XXH128 hash algorithm of the xxHash library, which
generates a 128-bit hash. It is implemented as a streaming hash, which
generates the hash with minimal extra memory usage.
Objects are converted to binary using R's native serialization tools.
On R >= 3.5.0, serialization version 3 is used, otherwise version 2 is used.
See serialize()
for more information about the serialization version.
hash(c(1, 2, 3)) hash(mtcars)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.