similar to: a handy function "format.cardinal", looking for a proper name..

Displaying 20 results from an estimated 30000 matches similar to: "a handy function "format.cardinal", looking for a proper name.."

1998 Jul 01
1
ordinal(): [was "a handy function ..." in March..]
I'm finally cleaning up old things / todo's; We had about half a dozen e-mails on R-devel back in mid March...... Here is my proposal, a sometimes useful utility for constructing strings in cat() or text(), legend(), etc.: ordinal <- function(i, language =3D "english", gender =3D c("female","male"), sep=3D""= ) { ii <- i
2007 Mar 01
1
Strange behavior scale and switcher plugin after update
Hi, I have noticed a strange behavior: after the added one of the options "window_match" in scale and switcher plugins; these do not show some windows like gmplayer or amsn's windows This is the output of xprop $ xprop _NET_WINDOW_DECOR(INTEGER) = 20061011, 46149375, 4, 4, 27, 4, 4, 4, 27, 4, 9, 0, 36965, -11, -34, -68, 0, 582, 32767, 0, 0, 32869, 571, -34, -68, 0, 32767,
2016 Jul 22
3
[PATCH RFC supermin] ext2_initrd: error out if we can't add anything
From: Chen Hanxiao <chenhanxiao@gmail.com> If we failed to add something to initrd, just error out. Signed-off-by: Chen Hanxiao <chenhanxiao@gmail.com> --- src/ext2_initrd.ml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ext2_initrd.ml b/src/ext2_initrd.ml index d4a4e2f..d9a3a99 100644 --- a/src/ext2_initrd.ml +++ b/src/ext2_initrd.ml @@ -151,8
2011 Oct 04
1
a question about sort and BH
Hi, I have two questions want to ask. 1. If I have a matrix like this, and I want to figure out the rows whose value in the 3rd column are less than 0.05. How can I do it with R. hsa-let-7a--MBTD1 0.528239197 2.41E-05 hsa-let-7a--APOBEC1 0.507869409 5.51E-05 hsa-let-7a--PAPOLA 0.470451884 0.000221774 hsa-let-7a--NF2 0.469280186 0.000231065 hsa-let-7a--SLC17A5
2008 Jul 04
2
create a zero matrix & fill
Dear R user, I have written a function which returns max,min and variation of a power (see below) Power is a given matrix(1,n) I call the function >Variation<-VAR(p,(n-deltat)) Now the problem is when I want plot(Results[1],Results[2]). Not possible! I become the following error (in english it means: Error in as.double.default(x) :Object cannot be transformed in double) >
2003 Jan 31
2
minor error in documentation of pmax in base (PR#2513)
The documentation says, "pmax and pmin take several vectors as arguments and return a single vector giving the parallel maxima (or minima) of the vectors." I discovered that, if you use a matrix or array instead of a vector, pmax returns a matrix or array, respectively. This makes pmax and pmin much more useful, and should not be left to people to discover on their own! For example:
2015 Mar 25
2
[LLVMdev] Optimization puzzle...
Hi everyone, I am wondering what¹s stopping the LLVM optimizer (opt -O3) from eliminating the apparently useless « icmp sgt » instruction in the following piece of LLVM IR. > ; ModuleID = 'lambda-opt.bc' > target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" > target triple = "x86_64-apple-macosx10.10.0" > > ; Function
2012 Oct 30
4
There is pmin and pmax each taking na.rm, how about psum?
Hi, Please consider the following : x = c(1,3,NA,5) y = c(2,NA,4,1) min(x,y,na.rm=TRUE) # ok [1] 1 max(x,y,na.rm=TRUE) # ok [1] 5 sum(x,y,na.rm=TRUE) # ok [1] 16 pmin(x,y,na.rm=TRUE) # ok [1] 1 3 4 1 pmax(x,y,na.rm=TRUE) # ok [1] 2 3 4 5 psum(x,y,na.rm=TRUE) [1] 3 3 4 6 # expected result Error: could not find function "psum" # actual result
2010 Mar 29
1
Suggestion: Adding quick rowMin and rowMax functions to base package
Hi, I wonder whether similarly to the very quick rowSums and colSums functions in the base package, one could add quick functions that calculate the min or max over rows / cols in a matrix. While apply(x,1,min) works, I found out by profiling a program of mine that it is rather slow for matrices with a very large number of rows. A quick functionality seems to be already there in the
2015 Dec 24
2
override pmin/pmax for my own matrix
Hello, I'm trying to override pmin and pmax for my own matrix. These two functions have ... as an argument. I tried to override them as follows: setMethod("pmax", class_name, function(x, ..., na.rm) { ... }) I use this way to override primitive functions such as min/max and it works fine. But it doesn't work for pmin and pmax. I guess because they are regular functions? How
2015 Mar 25
3
[LLVMdev] Optimization puzzle...
Here's a version that doesn't try to do block deletion on it's own. If you use -adce then -simplifycfg, you get what you want. It passes all tests except one, which is that we delete an invoke of a pure function, IE Transforms/ADCE/dce_pure_invoke.ll - I'm not sure why that's bad. The reason we delete it is because it returns false to I.mayHaveSideEffects(), and in particular,
2010 Feb 12
2
for loop function output
Hello all, I am trying to run a simulation. the simulation presented below. > rep=5 > sr=.10 # selection ratio > pmin=.10 # minority ratio > nap=1000 # total number of applicant > nsle=sr*nap # number of ee selected > nb=nap*pmin # number of minority > nw=nap-nb # number of majority > mb=100 # mean minority > sb=15 # sd minority > mw=100 # mean majority > sw=15 #
2008 Jul 04
1
initialize a matrix
Dear R users, I'm trying to write a function which returns minimum,maximum,mean of a vector(power) I've done the following : VAR<-function(power,length){ for(i in tml:length)){ tvar[i]<-i pmean[i]<-mean(power[i:i+deltat]) pmin[i]<-min(power[i:i+deltat]) pmax[i]<-max(power[i:i+deltat]) varmax[i]<-100*(pmax[i]-pmean[i])/pmean[i]
2008 May 13
2
array dimension changes with assignment
Why does the assignment of a 3178x93 object to another 3178x93 object remove the dimension attribute? > GT <- array(dim = c(6,nrow(InData),ncol(InSNPs))) > dim(GT) [1] 6 3178 93 > SNP1 <- InSNPs[InData[,"C1"],] > dim(SNP1) [1] 3178 93 > SNP2 <- InSNPs[InData[,"C2"],] > dim(SNP2) [1] 3178 93 > dim(pmin(SNP1,SNP2)) [1] 3178 93
2004 Dec 22
2
outer(-x, x, pmin) cannot allocate
R> x <- 0. + 1:8000 R> y <- outer(-x, x, pmin) Error: cannot allocate vector of size 1000000 Kb Why does R need to allocate a gigabyte to create an 8000 x 8000 matrix? It doesn't have any trouble with outer(-x, x, "+"). Thanks. -- David Brahm (brahm at alum.mit.edu) Version: platform = i686-pc-linux-gnu arch = i686 os = linux-gnu system = i686, linux-gnu status =
2011 Jul 04
1
Contrastes con el paquete survey (svycontrast)
Estimados usuarios: Estoy intentando reproducir el ejemplo 6.4 de Thomas Lumley. Complex Survey. Editorial Wiley. 2010 (ver la página en google:
2008 Apr 27
1
parallel max, min, and median of dataframe columns
Hello, all, I have a dataframe of three rows and umpteen columns. I want to show the maximum, minimum, and median with a vertical line and a central dot (I'd use a boxplot, but with only three data points, that's overkill; I can't just use points, because of overlap and some of the other data plotted on the graph). This works: > boxplot(data_frame,
2014 Jun 18
4
[LLVMdev] [RFC] Add a simple soft-float class
On Jun 18, 2014, at 1:20 PM, Duncan P. N. Exon Smith <dexonsmith at apple.com> wrote: > I'm certainly not suggesting this would be better in general than IEEE 754. > > But I think it's suitable for the sorts of places we currently use > hard-floats. I guess you (and Philip) are saying there are dragons here? Numerical analysis is hard. Every numerics expert I have
2004 Sep 13
1
an integration question
Dear all, I'm stuck on a problem concerning integration..Results from the analytical expression and numerical approximation (as returned by integrate()) do not match. It probably depends on some error of mine, so apologizes for this off-topic question. I'm interested in computing the integral of f where: f<-function(x){exp(-3-.2*pmin(x-7.5,0))} x<-seq(0,15,length=50) plot(x,
2010 Sep 21
5
Combined plot: Scatter + density plot
Hi, in order to save space for a publication, it would be nice to have a combined scatter and density plot similar to what is shows on http://addictedtor.free.fr/graphiques/RGraphGallery.php?graph=78 I wonder if anybody perhaps has already developed code for this and is willing to share. This is the reproducible code for the histogram version obtained from the site: def.par <-