Re: [R] loop for a large database

2012-02-27 Thread mari681
2012/2/27 Petr Savicky [via R] > On Sun, Feb 26, 2012 at 11:39:01AM -0800, mari681 wrote: > > > SORRY! > > > > The data in MyTable are tagsets of photos, like this: > > > > V1 V2 V3 V4 V5 V6V7 V8 > > 230green nailpolish barrym 0 0

Re: [R] loop for a large database

2012-02-27 Thread Petr PIKAL
Hi > > SORRY! > > The data in MyTable are tagsets of photos, like this: > > V1 V2 V3 V4 V5 V6V7 V8 > 230green nailpolish barrym 0 00 00 > 231 ny green brooklyn cleanup clean gowanus volunteer gcc

Re: [R] loop for a large database

2012-02-27 Thread Petr Savicky
On Sun, Feb 26, 2012 at 11:39:01AM -0800, mari681 wrote: > SORRY! > > The data in MyTable are tagsets of photos, like this: > > V1 V2 V3 V4 V5 V6V7 V8 > 230green nailpolish barrym 0 00 00 > 231 ny gree

Re: [R] loop for a large database

2012-02-26 Thread mari681
Thank you!! MyTable has 21 millions rows and 15 columns, and the data is "character", they are words. When I tried the loop my computer crashed in the meaning that it freezed (froze?) and didn't allow me to do anything. The morning after I forced it off and rebooted. :-) Thank you so much, I'll t

Re: [R] loop for a large database

2012-02-26 Thread mari681
SORRY! The data in MyTable are tagsets of photos, like this: V1 V2 V3 V4 V5 V6V7 V8 230green nailpolish barrym 0 00 00 231 ny green brooklyn cleanup clean gowanus volunteer gcc 232green s

Re: [R] loop for a large database

2012-02-26 Thread chuck.01
Untested die to no data, but this should work with a loop out=vector("list", length= length(MyVector)) for(i in 1 : length (MyVector)) { x <- data.frame (sum (MyTable ==MyVector[i])) out[[i]] <- x } sum(do.call(rbind, out)) -- View this message in context: http://r.789

Re: [R] loop for a large database

2012-02-26 Thread Petr Savicky
On Sun, Feb 26, 2012 at 04:13:49AM -0800, mari681 wrote: > Yes, I am a newbie. > > I have a data.frame (MyTable) of 1445846 rows and 15 columns with > character data. > And a character vector (MyVector) of 473491 elements. > > I want simply to get a data.frame with the count of how many times

Re: [R] loop for a large database

2012-02-26 Thread Petr Savicky
On Sun, Feb 26, 2012 at 04:13:49AM -0800, mari681 wrote: > Yes, I am a newbie. > > I have a data.frame (MyTable) of 1445846 rows and 15 columns with > character data. > And a character vector (MyVector) of 473491 elements. > > I want simply to get a data.frame with the count of how many times

Re: [R] loop for a large database

2012-02-26 Thread David Winsemius
On Feb 26, 2012, at 7:13 AM, mari681 wrote: Yes, I am a newbie. I have a data.frame (MyTable) of 1445846 rows and 15 columns with character data. And a character vector (MyVector) of 473491 elements. I want simply to get a data.frame with the count of how many times each element of MyV

[R] loop for a large database

2012-02-26 Thread mari681
Yes, I am a newbie. I have a data.frame (MyTable) of 1445846 rows and 15 columns with character data. And a character vector (MyVector) of 473491 elements. I want simply to get a data.frame with the count of how many times each element of MyVector appears in MyTable. I've tried a loop with :