MINI MINI MANI MO
%
% Copyright (c) 2012, 2014, Oracle and/or its affiliates. All rights reserved.
%
\name{ore.hash}
\alias{ore.hash}
\alias{ore.hash,ANY-method}
\alias{ore.hash,ore.vector-method}
\title{Oracle R Enterprise ore.vector Hash Function}
\description{
Hashes the values in an \code{\linkS4class{ore.vector}} object.
}
\usage{
ore.hash(x, ...)
\S4method{ore.hash}{ore.vector}(x, size = 4294967296,
seed = round(runif(1, min = -0.5, max = 4294967295.5)), ...)
}
\arguments{
\item{x}{
An \code{\linkS4class{ore.vector}} object.
}
\item{size}{
A numeric value within \code{[1, 4294967296]} representing the total
number of hash buckets.
}
\item{seed}{
A numeric value within \code{[0, 4294967295]} representing the seed
value for the hash function.
}
\item{...}{
For future expansion.
}
}
\details{
For the Oracle Database, the SQL snippet
\code{ORA_HASH(<SQL expr>, size - 1, seed) + 1} is used to calculate the
hash value.
}
\value{
Returns an \code{\linkS4class{ore.numeric}} object containing the hash
values for the original vector.
}
\references{
\href{http://www.oracle.com/technetwork/database/database-technologies/r/r-enterprise/documentation/index.html}{Oracle R Enterprise}
}
\author{
Oracle \email{oracle-r-enterprise@oracle.com}
}
\seealso{
\code{\linkS4class{ore.vector}}, \code{\link{ore.recode}}
}
\examples{
vec <- ore.push(c("a", "b", "a", NA, "c", "e"))
ore.hash(vec, seed = 123)
}
\keyword{utilities}
\keyword{database}
\keyword{ORE}
OHA YOOOO