Displaying 20 results from an estimated 3000 matches similar to: "Naming functions for the purpose of profiling"
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
2012 Dec 11
1
Debian packaging and openblas related crash when profiling in R
Hello R-sig-debian and (hopefully) Dirk:
On Debian wheezy, I have the R packaging that CRAN (you) provide. I
run into a little trouble while trying to fiddle with alternative
BLAS.
I know you and I went around on this last year and I think perhaps
I've found something wrong in the framework, or I've just done
something wrong.
I installed the packages openblas-base and openblas-dev, and
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
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(),
2010 Nov 19
1
memory profiling
I'm trying to configure Version 2.12.0 or R to do memory profiling.
I've reconfigured the code:
% ./compile --enable-memory-profiling=YES
and verified that it's configured correctly by examining the output. I then
rebuild R:
% make
Then I fire up R and run a script, using Rprof with the memory-profiling
switch set to TRUE:
Rprof("output", memory.profiling=TRUE);
# a
2004 Jul 16
3
interpreting profiling output
I have some trouble interpreting the output from profiling. I have
read the help pages Rprof, summaryRprof and consult the R extensions
manual, but I still have problems understanding the output.
Basically the output consist of self.time and total.time. I have the
understanding that total.time is the time spent in a given function
including any subcalls or child functions or whatever the
2017 May 18
1
Interpreting R memory profiling statistics from Rprof() and gc()
Sorry, this might be a really basic question, but I'm trying to interpret
the results from memory profiling, and I have a few questions (marked by
*Q#*).
From the summaryRprof() documentation, it seems that the four columns of
statistics that are reported when setting memory.profiling=TRUE are
- vector memory in small blocks on the R heap
- vector memory in large blocks (from malloc)
- memory
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
2012 Dec 05
1
Understanding svd usage and its necessity in generalized inverse calculation
Dear R-devel:
I could use some advice about matrix calculations and steps that might
make for faster computation of generalized inverses. It appears in
some projects there is a bottleneck at the use of svd in calculation
of generalized inverses.
Here's some Rprof output I need to understand.
> summaryRprof("Amelia.out")
$by.self
self.time self.pct
2009 Mar 03
1
profiler and loops
Hello,
(This is follow up from this thread:
http://www.nabble.com/execution-time-of-.packages-td22304833.html but
with a different focus)
I am often confused by the result of the profiler, when a loop is
involved. Consider these two scripts:
script1:
Rprof( )
x <- numeric( )
for( i in 1:10000){
x <- c( x, rnorm(10) )
}
Rprof( NULL )
print( summaryRprof( ) )
script2:
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
2004 Oct 16
7
sapply and loop
Dear all,
I am doing 200 times simulation. For each time, I generate a matrix and
define some function on this matrix to get a 6 dimension vector as my
results.
As the loop should be slow, I generate 200 matrice first, and save them into
a list named ma,
then I define zz<-sapply(ma, myfunction)
To my surprise, It almost costs me the same time to get my results if I
directly use a loop
2004 Oct 16
7
sapply and loop
Dear all,
I am doing 200 times simulation. For each time, I generate a matrix and
define some function on this matrix to get a 6 dimension vector as my
results.
As the loop should be slow, I generate 200 matrice first, and save them into
a list named ma,
then I define zz<-sapply(ma, myfunction)
To my surprise, It almost costs me the same time to get my results if I
directly use a loop
2012 Jul 21
1
alternative to rbind for data.table
Hi
I want to add a row to a "data.table" in each round of a for loop.
"rbind" seems to be a inefficient way to implement this.
How would you do this? The "slow" solution:
library(data.table)
Rprof("test.out")
dt <- data.table()
for (i in (1:10000)) {
# algorithm that generates a list with different values,
# but same key-names, each round, for
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 ...
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
2008 Aug 26
1
Dramatic slowdown of R 2.7.2?
Dear R users/developers,
simple comparison of code execution time of R 2.7.1 and R 2.7.2 shows a
dramatic slowdown of the newer version. Rprof() identifies .Call
function as a main cause (see the code below). What happened with R
2.7.2?
Kind regards
Marek Wielgosz
Bayes Consulting
######### Probably useful info ###############
### CPU: Core2Duo T 7300, 2 GB RAM
### WIN XP
### both standard
2013 Oct 24
2
Rarezas con boot
la libreria lm4 cambio con la versón 3 de R. Fijate en las versiones
Prof. Julio Di Rienzo
Estadística y Biometría
FCA- U.N. Córdoba
IBS-RARG President
http://sites.google.com/site/juliodirienzo
"Biometry, the active pursuit of biological
knowledge by quantitative methods."
(R.A. Fisher, 1948)
2013/10/24 Carlos Ortega <cof@qualityexcellence.es>
> Hola,
>
> Quizás para
2013 Mar 05
2
Function completely locks up my computer if the input is too big
Dear r-help,
Somewhere in my innocuous function to rotate an object in Cartesian space
I've created a monster that completely locks up my computer (requires a
hard reset every time). I don't know if this is useful description to
anyone - the mouse still responds, but not the keyboard and not windows
explorer.
The script only does this when the input matrix is large, and so my initial
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),