[R] Multiple String word replacements: Performance Issue

2013-11-06 Thread Simon Pickert
Dear experts, I’ve been on this for weeks now, and couldn’t find a solution..Sorry for the long description. I figured I post many details, so you get the problem entirely, although it’s not hard to grasp. **Situation:** Data frame consisting of 4 million entries (total size: 250 MB). Two column

Re: [R] How can I use muliple cores of CPU in Windows or OS X?

2013-11-05 Thread Simon Pickert
Mcapply from package 'parallel'. Also see package 'multicore' > Am 06.11.2013 um 00:01 schrieb Agony : > > Dear all, > > I have about 50 pages of R codes and ran it in both OS X and Windows. > It takes at least haft a day to have the results. The running time is not > very different in both Sy

Re: [R] speed issue: gsub on large data frame

2013-11-05 Thread Simon Pickert
xpressions are used, not just in R. also >> some idea of what the timing is; are you talking about 1-10-100 >> seconds/minutes/hours. >> >> Sent from my iPad >> >> On Nov 5, 2013, at 3:13, Simon Pickert wrote: >> >>> How’s that not reproducib

Re: [R] speed issue: gsub on large data frame

2013-11-05 Thread Simon Pickert
--- > Sent from my phone. Please excuse my brevity. > > Simon Pickert wrote: >> Hi R’lers, >> >> I’m running into speeding issues, performing a bunch of >> >> „gsub(patternvector, [token],dataframe$text_column)" >> >> on a data frame

[R] speed issue: gsub on large data frame

2013-11-04 Thread Simon Pickert
Hi R’lers, I’m running into speeding issues, performing a bunch of „gsub(patternvector, [token],dataframe$text_column)" on a data frame containing >4millionentries. (The “patternvectors“ contain up to 500 elements) Is there any better/faster way than performing like 20 gsub commands in a row

[R] Placeholders for String Operations

2013-09-04 Thread Simon Pickert
Hi all, what are the placeholders for string operations/modifications? Is there a placeholder for numbers, which would allow me to easily replace all numbers in a string? Something like text1 <- c("this is a number 23%") text2 <- c("this is not a number bla%") newtext1 <- gsub(#%, [percentagev