1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/clone.R
\name{clone}
\alias{clone}
\alias{clone.default}
\title{Cloning ff and ram objects}
\usage{
clone(x, ...)
\method{clone}{default}(x, ...)
}
\arguments{
\item{x}{\code{x} an R object}
\item{\dots}{further arguments to the generic}
}
\value{
an object that is a deep copy of x
}
\description{
\command{clone} physically duplicates objects and can additionally change
some features, e.g. length.
}
\details{
\command{clone} is generic. \command{clone.default} handles ram objects.
Further methods are provided in package 'ff'.
\command{still.identical} returns TRUE if the two atomic arguments still
point to the same memory.
}
\section{Methods (by class)}{
\itemize{
\item \code{default}: default method uses R's C-API 'duplicate()'
}}
\examples{
x <- 1:12
y <- x
still.identical(x,y)
y[1] <- y[1]
still.identical(x,y)
y <- clone(x)
still.identical(x,y)
rm(x,y); gc()
}
\seealso{
\code{clone.ff}, \code{\link{copy_vector}}
}
\author{
Jens Oehlschlägel
}
\keyword{IO}
\keyword{data}
|