search for: ffor

Displaying 5 results from an estimated 5 matches for "ffor".

Did you mean: for
2009 Mar 03
1
profiler and loops
...3.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: Rprof( ) ffor <- function(){ x <- numeric( ) for( i in 1:10000){ x <- c( x, rnorm(10) ) } } ffor() Rprof( NULL ) print( summaryRprof( ) ) []$ time Rscript --vanilla script1.R $by.self self.time self.pct total.time total.pct "rnorm" 0.22 100 0.22 100...
2011 Dec 14
1
Hi
...: > > I want to create a matrix (or data frame) for instance from file KT80.csv > to KT81.csv so that the rows are without header and position. > > > > 127.18 > 1.06 > > > Wich function would help me? > > I think I should use something like > > > > ffor (i in 80:81){ > > files <- paste('KT', i, '.csv', sep = '') > > myfun <- function(d) { > > da1 <- read.csv(d) > > Output[i,1]=da1[1,2] > > > > } > > lout<- lapply(files, myfun) > > } > > But results that says...
2010 Aug 31
0
Export Results to a txt file applying a function to a list
...*****\nDataset Sim : ", i ) d<-data%*%t(data) s<-solve(d) print(s) out<-s out } ######First using for I take my results (for some element of a list I can't have results due to invertibility or convergence problem helpful suggestion of Joris Meys ) results<-list() ffor(i in 1:5){ tmp <- try(fun(data=S[[i]])) results[[i]] <- ifelse(is(tmp,"try-error"),NA,tmp) } #####and so I can see using "cat" the results for each dataset. #####I want to use lapply at the last step istead of for to make faster my program results <- lapply...
2012 Sep 14
0
problem with user defined panel function in xyplot
...graph as i want it. Now i want to use this graph as a panel function in xyplot function from lattice to get the nice lattice type of graph for all my categories in my time series. And ?.. i am getting this error:" Error using packet 1, Argument "ts01" is missing with no default"fFor each of my columns. ? Now my function called panel.tsfold takes as argument one column from a time series or a zoo object that has only 1 time series. How can i make the xyplot function to send to the panel function one column from the bigger time series dataset? ? My command that gives me erro...
2004 Apr 06
20
Off topic
Hello, I''m going to be helping a friend setup Shorewall in place of his Cisco router on his home network. Shorewall will be acting as the router/firewall gateway for internet access for his home LAN. His connection to the ISP is via PPPOE. Nothing unfamiliar here to me. It will be a standard 2 interface setup. My curiosity was peaked when he said that he is going to be installing