[R] paired samples, matching rows, merge()

Gabor Grothendieck ggrothendieck at gmail.com
Fri Aug 20 15:22:29 CEST 2010


On Fri, Aug 20, 2010 at 9:07 AM, Cecilia Carmo <cecilia.carmo at ua.pt> wrote:
> This is what I need, but my dataframe has many rows and it returns to me the
> following message:
>
> Error: cannot allocate vector of size 120 Kb
> In addition: There were 18 warnings (use warnings() to see them)
>

Assuming that its the merge command that generated the error try this
sqldf instead of the merge line:

library(sqldf)
sqldf("select * from x, y using(k1, k3)", dbname = tempfile())

You can also try it without dbname = tempfile() but that has a higher
chance of overflowing memory.
See http://sqldf.googlecode.com for more info on sqldf.



More information about the R-help mailing list