From gomez.matthieu at gmail.com  Tue Sep 30 23:20:48 2014
From: gomez.matthieu at gmail.com (Matthieu Gomez)
Date: Tue, 30 Sep 2014 17:20:48 -0400
Subject: [Rd] Shallow copies
Message-ID: <CAE2Fiwnz9RkqpPvKfU=WkgqJiLfZyH-Xw=mmzR+c6F-7BVhpQg@mail.gmail.com>

I have a question about shallow copies in R. Since R 3.1.0, subsetting
a dataframe with respect to its columns no longer result in deep
copies. This is an amazing change in my opinion. Now, subsetting a
data.frame by rows (or subsetting a matrix by columns or rows) still
does deep copies. In particular, it is my understanding that running a
command on a very large subset of rows (say "sum" or "biglm" on non
outliers observations) results in a deep copy of these rows first,
which can require twice as much the memory of the original
data.frame/matrix. If this is correct, I would be very interested to
know more on whether this behavior can/may change in future versions
of R.

Thanks a lot!,
Matthew



[Rd] Shallow copies
Matthieu Gomez