similar to: Comparing execution times

Displaying 19 results from an estimated 19 matches similar to: "Comparing execution times"

2011 Apr 11
1
Mclapply and print statement
Dear all. I am using the mclapply function to split my code to the many cores my system has. It seems that is working fine. This is the parallel version of lcapply. The only problem that I seem to have is that the printf cannot print messages. The ideal to me is to have fro my function an output of the form Shadowlist<-mclapply(1:dimz, function(i) { print(sprintf('Creating the
2011 Apr 09
1
For->lapply->parallel apply
Dear all, I would like to ask your help understand the subsequent steps for making my program faster. The following code: Gauslist<-array(data=NA,dim=c(dimx,dimy,dimz)) for (i in c(1:dimz)){ print(sprintf('Creating the %d map',i)); Gauslist[,,i]<-f <- GaussRF(x=x, y=y, model=model, grid=TRUE,param=c(mean,variance,nugget,scale,Whit.alpha)) } creates 100 GaussMaps (each
2011 Jul 22
0
Mclapply prints once
Dear all I have the following code that works in paraller (and is pretty fast actually) The only problem I still have is that every core just prints only once. dimz<-1000 Shadowlist<-mclapply(1:dimz, function(i) { ????????????????????????????? print(sprintf('Creating the %d map',i)); ????????????????????????????? createField(x=x, y=y, model=model,
2002 Sep 30
0
using step function in functions
Help! I am a new R user. It has been slow getting up to speed, but definitely rewarding. I have come up against a problem I can't handle. I would very much appreciate any help. I am writing a vector auto regression (VAR) function that utilizes existing R statistical functions. I would like to use the step function to do step-wise elimination on each univariate time series model. No
2011 Apr 27
1
Eval to write many files
Dear all I am looking for a shorter way and more elegant to write the following for (i in c(1:length(Shadowlist))){ filename<-paste('/home/apa/maps/',model,i,'.mat',sep="") varname<-paste(model,'_shadow',i,sep="") eval(parse(text=paste('writeMat(filename,',varname,'=Shadowlist[[i]])',sep=""))) } actually I do not
2004 Dec 28
1
RandomFields: Controling seed with GaussRF
Hi, I'm using RF to simulate a correlated variable with GaussRF set.seed=1 GaussRF(sim.kfinegrid, grid=F, model="exponential", param=c(0,0.5,0,0.2)) However when I simulate again using the same random seed I get different results. > set.seed=1 > summary(GaussRF(sim.kfinegrid, grid=F, model="exponential", param=c(0,0.5,0,0.2))) Min. 1st Qu. Median Mean 3rd
2007 May 21
1
size limit in R?
Hi, Please see the email exchanges below. I am having trouble generating output that is large enough for our needs, specifically when using the GaussRF function. However, when I wrote Dr. Schlather (the author of the GaussRF function), he indicated that there is also a limit imposed by R itself. Is this something that we can overcome? Thank you very much for any assistance you may provde.
2011 Mar 30
4
a for loop to lapply
Dear all, I am trying to learn lapply. I would like, as a test case, to try the lapply alternative for the Shadowlist<-array(data=NA,dim=c(dimx,dimy,dimmaps)) for (i in c(1:dimx)){ Shadowlist[,,i]<-i } ---so I wrote the following--- returni <-function(i,ShadowMatrix) {ShadowMatrix<-i} lapply(seq(1:dimx),Shadowlist[,,seq(1:dimx)],returni) So far I do not get same results
2007 Feb 27
0
help with NSST models in GaussRf
Hi R-Users, I am ussing GaussRf in the Random Fields Package to generate spatial-temporal fields. I am having a hard time understanding how to use the NSST model. Does anybody have some experience with this model or any of the non-separable space time models available? I got all the papers cited in the manual but I am still lost. Thanks a lot Ele
2005 May 19
0
Random/systematic selection of rows in a matrix
Hi R people: I am new to R. I am writing a function to (1) produce a sparse stochastic Gaussian 2D field and (2) perform a systematic transect sampling on this field, this carried out many times in a simulation framework. My function does a good job at producing the random field (a matrix of zeros and some manifestations of the stochastic process, depending on a parameter of the function
2010 Sep 06
0
How R converts data between objects
Hello everyone. I would kindly request your help concerning how R converts data between different structrures. In the following example please keep attention on the following two 1) I create f <- GaussRF(x=x, y=y, model=model, grid=TRUE,param=c(mean, variance, nugget, scale, alpha)) with image(x,y,f) and image(f) I get exactly the same image. then 2)I try to store f inside a raster
2012 Nov 12
1
How to generate a random field with truncated marginal distributions?
I have asked the same question on stackoverflow but did not get a satisfying answer. I am trying to simulate a lognormal spatial random field but I need the simulated value in a certain range. So I need some easy to use functions to generate a truncated Gaussian field to start with. To be specific, I need a function like GaussRF from the RandomFields package or grf from the geoR package to
2004 May 11
1
bad interaction between RandomFields 1.1.11 and Sweave
Not really a bug (I eventually discovered), but ... When running GaussRF()/DoSimulateRF() with n>1, the default pch="!" prints backspaces to the terminal, which causes problems (LaTeX barfs) if you're running this within an Sweave() job. Setting RFparameters(pch="") fixes the problem. Could put this in the documentation, but I don't know where you could
2010 Sep 01
1
Looks like a bug in subsetting of a complicated object
I don't understand what is happening! I have a (large) object sim1, an matrix list with dim c(101,101) where each element is an 3*3 matrix. I am subsetting that with a matrix coo, of dim c(100,2), of unique indices, but the resulting object has length 99, not 100 as expected. Code reproducing the problem follows: library(RandomFields) set.seed(123) sim0 <- GaussRF(x=seq(0, 100, by=1),
2011 Sep 23
2
[LLVMdev] What CCAssignToXXXWithShadow means?
Hi, all On the website, it says, CCAssignToRegWithShadow <registerList, shadowList> — similar to CCAssignToReg, but with a shadow list of registers I don't know when we should use CCAssignToRegWithShadow. Because I am not a architecture expert, please bear with my naive question. Take ARMCallingConv.td as an example, CCIfType<[i32], CCIfAlign<"8",
2012 Feb 10
0
range and anisotropy with RandomFields
Hello, I am presently trying to get a feel for the various packages out there that allow me to both analyze and simulate random fields. The package RandomFields is nice, but there are still a few aspects of its implementation that are confusing to me and I was hoping someone could help clarify things for me. It could also be that my questions reflect a lack of knowledge pertaining to random
2010 Aug 19
0
2d kriging with anisotropy on an irregular network (RandomFields Package)
Dear List I am using the RandomFields package, and I have a problem when 2d-kriging, with an anisotropy, some values from an irregular network. It works well when : - 2d-kriging, without any anisotropy, some data from an irregular network - 2d-kriging, with and without anisotropy, some data from a regular network - 3d-kriging, with and without anisotropy, some data from a regular network Here is
2010 Mar 14
3
the error in DoSimulateRF function
Hello, I am a graduate student of University of Florida. I am trying to run a process variation model and I am facing the following error. ------------------------------------------------------------- Analysis of geostatistical data For an Introduction to geoR go to http://www.leg.ufpr.br/geoR geoR version 1.6-27 (built on 2009-10-15) is now loaded
2007 Aug 07
2
Spatial sampling problem
Hi All, I am new in R and trying to simulate random normal 2D field with mean trend say north-south. My domain is 10x10 grid and I am trying to use mvnorm but do not know how to specify the domain and the mean field. I would appreciate any help. Cheers, SK --------------------------------- [[alternative HTML version deleted]]