Re: [R] substract 2 data.frames

2011-02-27 Thread Nicolas Gutierrez
That worked! Gracias Jorge Nico On 2/27/2011 12:58 PM, Jorge Ivan Velez wrote: Hi Nicolas, Try popn[!rownames(popn) %in% rownames(fish), ] HTH, Jorge On Sun, Feb 27, 2011 at 3:29 PM, Nicolas Gutierrez <> wrote: Hi! I have 2 data.frames: "fish" and "popn": >fish xloc

Re: [R] substract 2 data.frames

2011-02-27 Thread Jorge Ivan Velez
Hi Nicolas, Try popn[!rownames(popn) %in% rownames(fish), ] HTH, Jorge On Sun, Feb 27, 2011 at 3:29 PM, Nicolas Gutierrez <> wrote: > Hi! > > I have 2 data.frames: "fish" and "popn": > > >fish > > xloc yloc id birth size weight energy gonad > 20 15 15 54 -60 107.9 63.0 15952.9 8

Re: [R] substract 2 data.frames

2011-02-27 Thread Jinyan Huang
I think paste all column together, then using a %in% b. Maybe others have better solution. On Sun, Feb 27, 2011 at 9:29 PM, Nicolas Gutierrez wrote: > Hi! > > I have 2 data.frames: "fish" and "popn": > >>fish > >   xloc yloc id birth  size weight  energy gonad > 20   15   15 54   -60 107.9   63.0

[R] substract 2 data.frames

2011-02-27 Thread Nicolas Gutierrez
Hi! I have 2 data.frames: "fish" and "popn": >fish xloc yloc id birth size weight energy gonad 20 15 15 54 -60 107.9 63.0 15952.9 8.0 21 15 15 32 -60 105.1 61.4 15538.8 7.8 914 43 96 -60 118.9 69.4 17573.2 8.8 71 324 64 -60 121.6 71.0 17976.0 9.0