similar to: Possible bug, Rprof() and scan(pipe()) (PR#1140)

Displaying 20 results from an estimated 10000 matches similar to: "Possible bug, Rprof() and scan(pipe()) (PR#1140)"

2002 Jun 11
2
Puzzled by what Rprof is telling me
I am using Rprof() to help find ways to improve performance. I found a function whose total seconds and self seconds were large. I replaced it with something else. The something else had a small number of total seconds and self seconds. But the total time did not decrease. I don't understand how that could be, and would appreciate any suggestions. Thanks -Don Details, unfortunately
2007 Aug 23
2
read big text file into R
Dear Rs: Hi, I am trying to read a big text file (nrows=243440, ncols=144). It seems the computational time of all the read methods (scan,readtable,read.delim) is not linear to the number of rows I want to read in: things became really slow once I tried to read in 100000 lines compare to 10000 lines). If I am reading the profiling result right, I guess scan wouldn't help either. My
2007 Oct 22
2
Help interpreting output of Rprof
Hello there, I am not quite sure how to interpret the output of Rprof (in the following the output I was staring at). I was poking around the web a little bit for documentation but without much success. I guess if I want to figure out what takes so long in my code the 2nd table $by.total and the total.pct column (pct = percent) is the most helpful. What does it mean that [ or [.data.frame is
2004 May 13
0
Rprof ignores top-level computation (PR#6883)
Full_Name: John Garvin Version: 1.9.0 OS: Linux Submission from: (NULL) (128.42.129.78) This may or may not technically be a bug, but it's certainly an annoyance. Rprof only takes into account computation that occurs inside functions. If a time-consuming operation occurs outside a function, it doesn't record the time it takes. Consider this program 'array.r': Rprof() foo <-
2009 Jun 12
1
Rprof loses all system() time
Rprof seems to ignore all time spent inside system() calls. E.g., this simple example actually takes about 10 seconds, but Rprof thinks the total time is only 0.12 seconds: > Rprof("sleep-system.out") ; system.time(system(command="sleep 10")) ; Rprof(NULL) user system elapsed 0.000 0.004 10.015 > summaryRprof("sleep-system.out")$by.total
2007 Mar 31
1
Probem with argument "append" in "Rprof"
Hello, Appending information to the profiler's output seems to generate problems. Here is a small example of code : <code r> require(boot) Rprof( memory.profiling = TRUE) Rprof(NULL) for(i in 1:2){ Rprof( memory.profiling = TRUE, append = TRUE) example(boot) Rprof(NULL) } </code> The problem is that the file Rprof.out contains more than once the header information: $ grep
2005 Jan 20
0
Interpreting Rprof output
Hello! I have run Rprof on a function of mine and the results look very strange, to say the least. At the end I of this email is an output of summaryRprof. Can someone help me interpret this output? I have read the appropriate section in the manual "Writing R Extensions" and help pages. If I understand this output correctly, it is saying that "unlist" has been active in
2011 Feb 22
1
Discrepancies in run times
Dear R-users, I am in the process of creating new custom functions and am quite puzzled by some discrepancies in execution time when I run some R scripts that call those new functions. So here is the situation: - let's assume I have created two custom functions, called myg and myf; - myg is mostly a plotting function, which makes a heavy use of grid and lattice functions; - myf is a function
2011 Feb 11
1
Help optimizing EMD::extrema()
Hi folks, I'm attempting to use the EMD package to analyze some neuroimaging data (timeseries with 64 channels sampled across 1 million time points within each of 20 people). I found that processing a single channel of data using EMD::emd() took about 8 hours. Exploration using Rprof() suggested that most of the compute time was spent in EMD::extrema(). Looking at the code for EMD:extrema(),
2009 Nov 10
1
standardGeneric seems slow; any way to get around it?
Hi, I'm running some routines with standard matrix operations like solve() and diag(). When I do a profile, the lead item under total time is standardGeneric(). Furthermore, solve() and diag() have much greater total time than self time. ??? I assume there is some time-consuming decision going on in the usual functions; is there any way to avoid that and go straight to the calculaions? Thanks
2012 Dec 11
1
Rprof causing R to crash
I'm trying to use Rprof() to identify bottlenecks and speed up a particullary slow section of code which reads in a portion of a tif file and compares each of the values to values of predictors used for model fitting. I've written up an example that anyone can run. Generally temp would be a section of a tif read into a data.frame and used later for other processing. The first portion
2002 Jul 19
1
Rprof and setMethod conflict?
I noticed this oddity about R profiling and setMethod. First, I "test out" Rprof. > require(methods) Loading required package: methods [1] TRUE > > Rprof("test.out") > data.frame("a") X.a. 1 a > Rprof(NULL) So far, so good. Next, I define myClass. > setClass("myClass", representation(mySlot = "numeric")) [1]
2011 Feb 28
0
Fwd: Re: speed up process
Dear Jim, Here is again exactly what I did and with the output of Rprof (with this reduced dataset and with a simpler function, it is here much faster than in real life). Thanks you again for your help! ## CODE ## mydata1<- structure(list(species = structure(1:8, .Label = c("alsen","gogor", "loalb", "mafas", "pacyn", "patro",
2010 Jan 24
1
Categorical data repeated on time analysis
Hi, I am trying to analyze a data set when nematodes were killed after a drug administration. We have counted the number of nematode died and the number of nematode survival at three time points. So, there are 100% died in some plot and could be found zero percent in another. Then, the data set have a lot of zeros. I have googled and found a lot of information. Moreover, my data isn't
2009 Oct 19
2
how to get rid of 2 for-loops and optimize runtime
Short: get rid of the loops I use and optimize runtime Dear all, I want to calculate for each row the amount of the month ago. I use a matrix with 2100 rows and 22 colums (which is still a very small matrix. nrows of other matrixes can easily be more then 100000) Table before Year month quarter yearmonth Service ... Amount 2009 9 Q3 092009 A ...
2004 Jun 14
4
Quirks with system.time and simulations
I tried the code that Richard O'Keefe posted last week, to wit: library(chron) ymd.to.POSIXlt <- function (y, m, d) as.POSIXlt(chron(julian(y=y, x=m, d=d))) n <- 100000 y <- sample(1970:2004, n, replace=TRUE) m <- sample(1:12, n, replace=TRUE) d <- sample(1:28, n, replace=TRUE) system.time(ymd.to.POSIXlt(y, m, d)) [1] 8.78 0.10
2013 Mar 28
1
make R program faster
Hi there are some good tips in "The R Inferno" http://www.burns-stat.com/documents/books/the-r-inferno/ or connect C++ to R with Rcpp http://dirk.eddelbuettel.com/code/rcpp.html or byte code compiler (library(compiler)) or library(data.table) but do you have an idea to fasten standard R source code, with the following Rprof output self.time self.pct total.time
2004 Oct 16
3
Lazy loading... advices
Hello, I am looking for more information about lazy loading introduced in R 2.0.0. Doing ?lazyLoad I got some and there is a 'see also' section that points to 'makeLazyLoading'... But I cannot reach this page. My problem is: I recompiled a library that uses a lot of functions from other libraries (of course I can give details if needed). I load it in my computer: library(svGUI),
2013 Apr 05
2
line profiling
Hello, This is about the new "line profiling" feature in R 3.0.0. As I was testing it, I find the results somewhat disappointing so I'd like to get your opinion. I put some poorly written code in a test.R file, here are the contents: double <- function(x) { out <- c() for (i in x) { out <- c(out, 2*i) # line 4 } return(out) } Then this how I source the file
2003 Jul 15
1
Rprof
I find it difficult to find Rprof using the usual search tools... could I suggest that it be cross-referenced to profile Rprofile Profile to make this easier? url: www.econ.uiuc.edu/~roger/my.html Roger Koenker email rkoenker@uiuc.edu Department of Economics vox: 217-333-4558 University of Illinois fax: 217-244-6678 Champaign, IL 61820