MINI MINI MANI MO

Path : /opt/oracle/product/18c/dbhomeXE/R/library/OREbase/doc/man/zh_CN/
File Upload :
Current File : //opt/oracle/product/18c/dbhomeXE/R/library/OREbase/doc/man/zh_CN/ore.recode.Rd

%
% Copyright (c) 2012, 2014, Oracle and/or its affiliates. All rights reserved.
%
\name{ore.recode}
\alias{ore.recode}
\alias{ore.recode,ANY-method}
\alias{ore.recode,ore.vector-method}
\title{
Oracle R Enterprise ore.vector 值重新编码函数
}
\description{
重新编码 \code{\linkS4class{ore.vector}} 对象中的值。
}
\usage{
ore.recode(x, old, new, default = NULL)
}
\arguments{
  \item{x}{
一个 \code{\linkS4class{ore.vector}} 对象。
}
  \item{old}{
用于指定 \code{x} 中旧值的 \R 向量。
}
  \item{new}{
长度与参数 \code{old} 的值相同的 \R 向量,
    或者行数与用于指定新值的参数 \code{old} 相同的 
    \R 矩阵。
}
  \item{default}{
用于参数 \code{old} 中不匹配元素的单个值。
    如果为 \code{NULL}, 则不匹配的元素将转换为
    \code{NA} 值。
}
}

\value{
如果参数 \code{new} 是 \R 向量, 则返回表示
  重新编码向量的 \code{\linkS4class{ore.vector}} 对象。
  如果参数 \code{new} 是 \R 矩阵, 则返回
  \code{\linkS4class{ore.frame}} 对象, 其中参数 \code{new} 的
  每一列在返回值中生成对应的重新编码列。
}
\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.hash}}
}
\examples{
vec <- ore.push(c("a", "b", NA, "a", "c", NA, "e"))
ore.recode(vec, c("a", "b", "c"), c("able", "baker", "charlie"))
ore.recode(vec, c("a", "b", "c"),
           cbind(lower = c("able", "baker", "charlie"),
                 UPPER = c("ABLE", "BAKER", "CHARLIE")))
}
\keyword{utilities}
\keyword{database}
\keyword{ORE}

OHA YOOOO