similar to: Help me with writing function sort()

Displaying 20 results from an estimated 7000 matches similar to: "Help me with writing function sort()"

2000 Jul 05
1
Tukey.aov with split-plot designs
I am using R 1.1 with Redhat 6.2 and RW 1.001 with Win98 (the upkey doesn't work on my IBM either as has been previously reported by others). The function aov doesn't return either the residuals or the residual degrees of freedom for split-plot designs. If you use the following code from Baron and Li's "Notes on the use of R for psycology experiments and questionnaires"
2011 Aug 05
1
Main-effect of categorical variables in meta-analysis (metafor)
Dear R-experts! In a meta-analysis (metafor) I would like to assess the effect of two categorical covariates (A & B) whereas they both have 4 levels. Is my understanding correct that this would require to dummy-code (0,1) each level of each covariate (A & B)? However I am interested in the main-effects and the interaction of these two covariates and the dummy-coding would only allow to
2016 Apr 10
0
what is the faster way to search for a pattern in a few million entries data frame ?
On 04/10/2016 03:27 PM, Fabien Tarrade wrote: > Hi Duncan, >> Didn't you post the same question yesterday? Perhaps nobody answered >> because your question is unanswerable. > sorry, I got a email that my message was waiting for approval and when I > look at the forum I didn't see my message and this is why I sent it > again and this time I did check that the
2016 Apr 10
5
what is the faster way to search for a pattern in a few million entries data frame ?
Hi Duncan, > Didn't you post the same question yesterday? Perhaps nobody answered > because your question is unanswerable. sorry, I got a email that my message was waiting for approval and when I look at the forum I didn't see my message and this is why I sent it again and this time I did check that the format of my message was text only. Sorry for the noise. > You need to
2002 Sep 24
5
Floor type 0 and residues type 0 and 1
Hi, it seems to me as if all vorbis-files only contain floors of type 1 and residues of type 2. Is it possible to "force" the encoder to somehow create a vorbis-file with the other floor and residue types? Tor <p><p><p>=================================================================== EASY and FREE access to your email anywhere: http://Mailreader.com/
2013 Sep 25
1
Computing calculation among two vectors
Hi, Try: x<- 1:4 ?y<- c("*","/","-","+") res<-sapply(y,function(i) {x1<-expand.grid(x,x); unlist(lapply(paste0(x1[,1],i,x1[,2]),function(u) eval(parse(text=u))))}) row.names(res)<- as.character(interaction(expand.grid(x,x),sep="_")) head(res) #??? *?? /? - + #1_1 1 1.0? 0 2 #2_1 2 2.0? 1 3 #3_1 3 3.0? 2 4 #4_1 4 4.0? 3 5 #1_2 2 0.5
2012 Jan 04
1
function in R for my exercise
Hi R helpers! I have a question. I'm trying to create a function for an exercise. Here are the arguments I should include: x and y are numeric z is a name ("plus","minus","multiply","divide") and swap is logical. Here is what the function should do: When z="plus", then x+y is performed and so on for the other z names. It should give a NA
2013 Apr 29
2
Adding elements in data.frame subsets and also subtracting an element from the rest elements in data.frame
Dear R forum I have a data.frame as cashflow_df = data.frame(instrument = c("ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC", "ABC", "PQR", "PQR",
2002 Jan 11
1
rsync 2.5.1 server - strange logs
I've just upgraded my rsync server to 2.5.1 (before, I was using 2.4.6), without changing anything in /etc/rsyncd.conf, and now, I have this logs each time a client connect to server: 2002/01/07 18:33:03 [10432] rsync: reverse name lookup mismatch on fd3 - spoofed address? 2002/01/07 18:33:03 [10432] rsync on admin/sbin/padmin_update.sh from UNKNOWN (172.16.65.14) 2002/01/07 18:33:03 [10432]
2019 Jul 03
2
Using bytecode version of std::sort for JIT generated data type
Hi LLVM devs, The performance of C++ std::sort comes from being able to inline the comparator. For a JIT generated data type, using the comparator as a function call from std::sort may not be ideal. So, i was wondering how can we make a JIT-sort which is as good as statically compiled std::sort with comparator inlined. What is the recommended way to pass a an existing function like std::sort into
2016 Mar 02
2
install.packages() fails with drat repository on networkdrive
Dear all, install.packages("lme4") fails with error Error in read.dcf(file = tmpf) : cannot open the connection In addition: Warning message: In read.dcf(file = tmpf) : cannot open compressed file '//servername/repository_path/bin/windows/contrib/3.2/PACKAGES', probable reason 'No such file or directory' the repositories set in .Rprofile are
2019 Jul 03
2
Using bytecode version of std::sort for JIT generated data type
Thanks David! I understand that std::sort doesn't exist without types especially at bytecode layer. What I was thinking was something like the following: Compile std::sort with a thunk function Compare(void*, void*) {rerturn false} into bytecode with an option say noinline and always make the function call or even a simple unoptimized bytecode which guarantees that Compare exists as a
2013 Jan 07
2
how to aggregate T-test result in an elegant way?
Dear all: Plan 1: I want to do serval t-test means for different variables in a loop , so I want to add all results to an object then dump() them to an text. But I don't know how to append T-test result to the object? I have already plot the barplot and I want to know an elegant way to report raw result. Can anybody give me some pieces of advice? Yao He ????????????????????????? Master
2017 Nov 28
2
dplyr - add/expand rows
Or with the Bioconductor IRanges package: df <- with(input, DataFrame(station, year=IRanges(from, to), record)) expand(df, "year") DataFrame with 24 rows and 3 columns station year record <character> <integer> <character> 1 07EA001 1960 QMS 2 07EA001 1961 QMC 3 07EA001 1962 QMC 4
2002 Apr 02
3
getaddrinfo() problem with AIX 4.3.3 and rsync 2.5.2?
I had to apply the following patch to the clientname.c check_name() function before I could successfully use "hosts allow" in rsyncd.conf. Without the patch I kept getting "rsync: forward name lookup for ... failed: Host not found" errors. These errors were produced by the rsync daemon, and putting in a debugging statement revealed that the port_buf being used had a large
2001 Jun 03
3
[xiphmont@xiph.org: [xiph-cvs] cvs commit: vorbis/vq huffbuild.c latticetune.c make_residue_books.pl]
Go monty! jack. ----- To: cvs@xiph.org Subject: [xiph-cvs] cvs commit: vorbis/vq huffbuild.c latticetune.c make_residue_books.pl Date: Sun, 3 Jun 2001 22:50:13 -0700 (PDT) From: xiphmont@xiph.org (Monty) Precedence: bulk Reply-To: cvs@xiph.org xiphmont 01/06/03 22:50:12 Modified: lib codebook.c codebook.h floor0.c mapping0.c os.h res0.c vq
2004 Jun 01
1
swapping with data.frame
Hi there, I have some data which are convenient to enter as lists. For example: t1<-list(fname="animal1",testname="hyla",dspkr="left",res1=39.7,res2=15.0) t2<-list(fname="animal1",testname="bufo",dspkr="left",res1=14.4,res2=56.1)
2015 Dec 28
3
Interpreting DSCallGraph results
Any suggestions for how to interpret DSCallGraph's output for the following? I'm trying to use DSCallGraph to get a conservative estimate of a whole-program SCC call graph. I wanted to see how it handles real call-graph cycles involving functions both internal and external to the module. So I made a test program with the following actual call graph, using the standard library's
2017 Nov 29
2
dplyr - add/expand rows
On 11/29/2017 04:15 PM, T?th D?nes wrote: > Hi, > > A benchmarking study with an additional (data.table-based) solution. I don't think speed is the right benchmark (I do agree that correctness is!). For the R-help list, maybe something about least specialized R knowledge required would be appropriate? I'd say there were some 'hard' solutions -- Michael (deep
2013 Nov 21
1
how can I import a number of datsets in a folder in my working directory to a list in R
Hi, Suppose, if I create 15 files in my working directory. set.seed(48) lapply(1:15,function(i) {m1 <- matrix(sample(1:20,1686*2,replace=TRUE),nrow=1686,ncol=2); write.table(m1,paste0("file_",i,".txt"),row.names=FALSE,quote=FALSE)}) ?D <-dir() D1 <- D[order(as.numeric(gsub("\\D+","",D)))] D1 ?res <- t(sapply(D1,function(x) {x1<-