hashCode {SparkR}R Documentation

Compute the hashCode of an object

Description

Java-style function to compute the hashCode for the given object. Returns an integer value.

Usage

hashCode(key)

Arguments

key

the object to be hashed

Details

This only works for integer, numeric and character types right now.

Value

the hash code as an integer

Examples

hashCode(1L) # 1
## [1] 1
hashCode(1.0) # 1072693248
## [1] 1072693248
hashCode("1") # 49
## [1] 49

[Package SparkR version 0.1 Index]