similar to: rank(, ties.method="last")

Displaying 20 results from an estimated 5000 matches similar to: "rank(, ties.method="last")"

2015 Oct 21
2
rank(, ties.method="last")
Marius Hofert-4------------------------------ > Den 2015-10-09 kl. 12:14, skrev Martin Maechler: > I think so: the code above doesn't seem to do the right thing. Consider > the following example: > > > x <- c(1, 1, 2, 3) > > rank2(x, ties.method = "last") > [1] 1 2 4 3 > > That doesn't look right to me -- I had expected > > >
2015 Oct 22
1
(no subject)
------------------ >>>>> Henric Winell <[hidden email]> >>>>> on Wed, 21 Oct 2015 13:43:02 +0200 writes: > Den 2015-10-21 kl. 07:24, skrev Suharto Anggono Suharto Anggono via R-devel: >> Marius Hofert-4------------------------------ >>> Den 2015-10-09 kl. 12:14, skrev Martin Maechler: >>> I think so: the code above
2015 Oct 20
0
rank(, ties.method="last")
On Tue, Oct 20, 2015 at 10:26 AM, Henric Winell <nilsson.henric at gmail.com> wrote: > Den 2015-10-09 kl. 12:14, skrev Martin Maechler: > I think so: the code above doesn't seem to do the right thing. Consider > the following example: > > > x <- c(1, 1, 2, 3) > > rank2(x, ties.method = "last") > [1] 1 2 4 3 > > That doesn't look right
2015 Jan 08
2
On base::rank
Have a look at the following, taken from base::rank: ... if (!is.na(na.last) && any(nas)) { yy <- integer(length(x)) # <~~~~~~~~~ storage.mode(yy) <- storage.mode(y) # <~~~~~~~~ yy <- NA NAkeep <- (na.last == "keep") if (NAkeep || na.last) { yy[!nas] <- y if (!NAkeep) yy[nas]
2017 Apr 12
3
"table(droplevels(aq)$Month)" in manual page of droplevels
The last line of the example in droplevels' manual page seems to be incorrect to me. I think it should read: "table(droplevels(aq$Month))". Amazingly (I don't understand) both variants seem to produce the same result (R 3.3.3): --- > aq <- transform(airquality, Month = factor(Month, labels = month.abb[5:9])) > aq <- subset(aq, Month != "Jul") >
2017 Feb 07
2
package load altering RNG state
>>>>> Henric Winell <nilsson.henric at gmail.com> >>>>> on Tue, 7 Feb 2017 13:37:42 +0100 writes: > Hi, On 2017-02-07 13:12, Benjamin Tyner wrote: >> Hello >> >> When loading a package, I'm wondering if it's frowned >> upon for the package to alter the state of the random >> number
2017 Apr 12
2
"table(droplevels(aq)$Month)" in manual page of droplevels
Hello, Inline. Em 12-04-2017 16:40, Henric Winell escreveu: > (Let's keep the discussion on-list -- I've added back R-devel.) > > On 2017-04-12 16:39, Ulrich Windl wrote: > >>>>> Henric Winell <nilsson.henric at gmail.com> schrieb am 12.04.2017 >>>>> um 15:35 in >> Nachricht <b66fe849-bb8d-f00d-87e5-553f866d57e0 at gmail.com>:
2014 Mar 06
2
'parallel' package changes '.Random.seed'
Hi, I've implemented parallelization in one of my packages using the 'parallel' package -- many thanks for providing it! In my package I'm importing 'parallel' and so added it to the DESCRIPTION file's 'Import:' tag and also added a 'importFrom("parallel", ...)' statement in the NAMESPACE file. Parallelization works nicely, but my package
2017 Feb 07
2
package load altering RNG state
Hello When loading a package, I'm wondering if it's frowned upon for the package to alter the state of the random number generator? I guess not, since the parallel package does it? > set.seed(6860) > old.seed <- .GlobalEnv$.Random.seed > library(parallel) > new.seed <- .GlobalEnv$.Random.seed > identical(old.seed, new.seed) [1] FALSE I ask
2013 May 30
1
wilcox_test function in coin package
Dear All, I have two simple data samples (no groups or factors, etc.) and would just like to compute the two-sample Wilcoxon Rank Sum test using the wilcox_test function contained in the coin package, which is reportedly better than the regular wilcox.test function because it performs some adjustment for ties. Would anyone know how to craft a script to perform this task? Much appreciated. Janh
2017 May 17
2
R-3.4.0 fails test
After installing R-3.4.0 I ran 'make check' which halted here: $ > tail reg-tests-1d.Rout.fail -n 16 > ## format()ing invalid hand-constructed POSIXlt objects > d <- as.POSIXlt("2016-12-06"); d$zone <- 1 > tools::assertError(format(d)) > d$zone <- NULL > stopifnot(identical(format(d),"2016-12-06")) > d$zone <- "CET" # =
2017 May 17
2
R-3.4.0 fails test
After installing R-3.4.0 I ran 'make check' which halted here: $ > tail reg-tests-1d.Rout.fail -n 16 > ## format()ing invalid hand-constructed POSIXlt objects > d <- as.POSIXlt("2016-12-06"); d$zone <- 1 > tools::assertError(format(d)) > d$zone <- NULL > stopifnot(identical(format(d),"2016-12-06")) > d$zone <- "CET" # =
2011 Sep 26
2
merger two 3-d scatter plot
Dear R groups: I have the data as follows, I want to plot the "Rank1 ~ obs30*Cases" and "Rank2 ~ obs30*Cases" on the same plot as one 3-D scatter plot, how to do that? Any help is highly appreciated. ID obs30 Cases RANK1 RANK2 1 0.03175 63 82 81 2 0.00000 34 1 34 3 0.00000 36 2 41 4 0.00000 54 3 26 5 0.00000 22 4 42 6 0.00746 134 39 32 7 0.00000 2 5 53 8 0.01190 168 46 31
2012 Aug 09
4
debug vs regular mode
Dear all, I had a R segmentation fault, and then invoked debug mode and ran step by step. When I reached "terms(Y~X1*X2*...*X16)", I would then have "segmentation" fault. However, if I just ran this under regular "R interactive" mode, it would be fine though taking long time. My questions are: 1. Is there a known limit of terms for a formula? 2. Why does the
2012 Aug 09
4
debug vs regular mode
Dear all, I had a R segmentation fault, and then invoked debug mode and ran step by step. When I reached "terms(Y~X1*X2*...*X16)", I would then have "segmentation" fault. However, if I just ran this under regular "R interactive" mode, it would be fine though taking long time. My questions are: 1. Is there a known limit of terms for a formula? 2. Why does the
2013 Jun 03
2
installing package 'rqpd' (Regression quantiles for panel data)
Hello R community members, I'm trying to install the 'rqpd' package which is developed by Roger Koenker and Stefan Bache. When I try to install the package using the command 'install.packages("rqpd",repos="http://R-Forge.R-project.org")' I'm getting the following two messages: i) package ?rqpd? is available as a source package but not as a binary
2006 Jun 21
5
rank(x,y)?
Suppose I have two columns, x,y. I can use order(x,y) to calculate a permutation that puts them into increasing order of x, with ties broken by y. I'd like instead to calculate the rank of each pair under the same ordering, but the rank() function doesn't take multiple values as input. Is there a simple way to get what I want? E.g. > x <- c(1,2,3,4,1,2,3,4) > y <-
2011 Nov 21
2
count ties after rank?
Hello! I need to use Kruskal-Wallis test and post-hoc test (Dunn's test) for my data. But when I searched around, I only found this function: kruskal.test. But nothing for Dunn's test. So I started to write one myself. But I do not know how to count ties in the data frame. I can use for loops but it seems long and unnecessary since the rank function actually knows the ties. So
2003 Jul 22
1
rank with ties
Hi, Is there a function like rank but that solves the ties by randomly assigning a value (doesn't average ranks of ties). This is what I actually need: I want to make NA all elements of each column in an array that are ranked in a position larger that rankmax for each column. # Say I've got an array b: b<-cbind(c(1:5,5:1),c(1,12,14,2,5,4:8)) #> b # [,1] [,2] #[1,] 1 1
2006 Aug 25
1
exact Wilcoxon signed rank test with ties and the "no longer under development" exactRanksumTests package
Dear List, after updating the exactRanksumTests package I receive a warning that the package is not developed any further and that one should consider the coin package. I don't find the signed rank test in the coin package, only the Wilcoxon Mann Whitney U-Test. I only found a signed rank test in the stats package (wilcox.test) which is able to calculate the exact pvalues but unfortunately