similar to: min/max of a vector with NAs and NaNs

Displaying 20 results from an estimated 20000 matches similar to: "min/max of a vector with NAs and NaNs"

2010 Oct 02
1
cleanup_pkg() in tools:::.build_packages() is broken
Hi, The cleanup_pkg() function defined the big tools:::.build_packages() function in tools/R/build.R is currently broken. When Makefiles are used cleanup_pkg() doesn't clean anything because of the way system2() is called. For example, the call to Ssystem() on line 304 (Ssystem is a silent version of system2) is basically trying to do this: >
2010 Oct 29
1
list2env() is broken
Hi, The following code produces different kinds of problems depending on which platform you run it: x <- as.list(1:200000) names(x) <- paste("A", 1:200000, sep="") e <- list2env(x) Timeout on Linux, crash on Mac and Windows, with R 2.12.0 and current R devel. The "multi-assign" mode (i.e. when the 'envir' arg is supplied) doesn't seem
2010 Oct 11
1
'R CMD build' not cleaning the src/ folder on Windows
Hi, 'R CMD build' (with R 2.12.0 RC) fails to clean the src/ folder on Windows: D:\biocbld\bbs-2.7-bioc>ls meat/BUS/src BUS.cpp BUS.h D:\biocbld\bbs-2.7-bioc>R\bin\R CMD build meat\BUS * checking for file 'meat\BUS/DESCRIPTION' ... OK * preparing 'BUS': * checking DESCRIPTION meta-information ... OK * cleaning src * installing the package
2010 Jun 04
2
Argument recycling in substring()
Hi, According to its man page substring() "expands (its) arguments cyclically to the length of the longest _provided_ none are of zero length". So, as expected, I get an error here: > substring("abcd", first=2L, last=integer(0)) Error in substring("abcd", first = 2L, last = integer(0)) : invalid substring argument(s) But I don't get one here:
2011 Feb 23
1
factor() on a double vector
Hi, When 'x' is a vector of doubles, it's not clear how 'factor(x)' compares its values in order to determine the levels. For example, here all the values in 'x' are "conceptually" the same: x <- c(11/3, 2/3 + 4/3 + 5/3, 50 + 11/3 - 50, 7.00001 - 1000003/300000) However, due to machine rounding errors, they are not
2020 Jan 02
1
New R function is.nana = is.na & !is.nan
"nana" is meant to express "NA, really NA". Your suggestion sounds good. On Thu 2 Jan, 2020, 3:38 AM Pages, Herve, <hpages at fredhutch.org> wrote: > Happy New Year everybody! > > The name (is.nana) doesn't make much sense to me. Can you explain it? > > One alternative would be to add an extra argument (e.g. 'strict') to > is.na(). FALSE by
2010 Sep 16
1
Lack of consistent cross-platform behaviour of tools:::buildVignettes()
Hi, On both Unix and Windows there is a mechanism to add variables to the environment when R is started. I noticed that, on Unix, this mechanism is not used when R is started normally at the command line but only when it's started using the 'R CMD' syntax. One problem with this is some lack of consistent cross-platform behaviour. For example: On Linux: $ echo $TEXINPUTS $
2011 Mar 25
2
two minor bugs in rowsum()
(a) In R 2.12.2 rowsum can overflow if given an integer input: > rowsum(c(2e9L, 2e9L), c("a", "a")) [,1] a -294967296 > 2^32 + .Last.value [,1] a 4e+09 Should it be changed to coerce its x argument to numeric (double precision) so it always returns a numeric output? (b) When rowsum is given an x containing both NaN and NA it appears to use the last
2020 Jan 01
2
New R function is.nana = is.na & !is.nan
Hello R-devel, Best wishes in the new year. I am writing to kindly request new R function so NA_real_ can be more easily detected. Currently if one wants to test for NA_real_ (but not NaN) then extra work has to be done: `is.na(x) & !is.nan(x)` Required functionality is already at C level so to address my request there is not that much to do. Kevin Ushey made a nice summary of current R C api
2010 Sep 30
1
tar problem when using 'R CMD build' on Windows
Hi, Already reported here: https://stat.ethz.ch/pipermail/r-devel/2010-September/058636.html but it doesn't seem to be related (at least not in an obvious way) to the problems described in that previous thread. So the problem is that, with recent versions of R 2.12 (i.e. current R-alpha but I've observed this with R-devel for at least 2-3 months now), 'R CMD build
2010 Nov 10
1
installed.packages Error: subscript out of bounds
Hi, Today we've seen the following problem with the R-2.12 that we use for our Windows builds: > installed.packages() Error: subscript out of bounds After some investigation we discovered that the cause of this failure was that 1 of the 890 packages currently installed on the machine (Windows Server 2003 R2) had its DESCRIPTION file empty:
2009 Sep 24
1
crash with NAs in subscripted assignment of a raw vector
Hi, > x <- charToRaw("ABCDEFGx") > x[c(1:3, NA, 6)] <- x[8] *** caught segfault *** address 0x8402423f, cause 'memory not mapped' Possible actions: 1: abort (with core dump, if enabled) 2: normal R exit 3: exit R without saving workspace 4: exit R saving workspace Cheers, H. > sessionInfo() R version 2.10.0 Under development
2010 Oct 22
1
cannot connect to an FTP server with long HELLO message
Hi, Trying to access files on the ftp server at ftp.ncbi.nih.gov will either give a time out or sometimes even a segfault on Linux. The 2 following methods give the same results: f <- url("ftp://ftp.ncbi.nih.gov/pub/geo/DATA/SOFT/GDS/GDS10.soft.gz", open="r") download.file("ftp://ftp.ncbi.nih.gov/pub/geo/DATA/SOFT/GDS/GDS10.soft.gz", destfile=tempfile())
2008 Dec 01
2
[BioC] BioC 2.3 standard installation
I always followed http://cran.r-project.org/bin/linux/ubuntu/ to install R on Ubuntu 8.1. I had no errors before! > install.packages("XML") Warning in install.packages("XML") : argument 'lib' is missing: using '/usr/local/lib/R/site-library' --- Please select a CRAN mirror for use in this session --- Loading Tcl/Tk interface ... done trying URL
2009 Jun 02
2
formal argument "envir" matched by multiple actual arguments
Hi list, This looks similar to the problem reported here https://stat.ethz.ch/pipermail/r-devel/2006-April/037199.html by Henrik Bengtsson a long time ago. It is very sporadic and non-reproducible. Henrik, do you remember if your code was using reg.finalizer()? I tend to suspect it but I'm not sure. I've been hunting this bug for months but today, and we the help of other Bioconductor
2010 Nov 12
1
installing dependencies: binary vs source
Hi, Installing from binaries on Windows: > install.packages("multtest") Warning: dependency 'Biobase' is not available trying URL 'http://cran.fhcrc.org/bin/windows/contrib/2.12/multtest_2.6.0.zip' Content type 'application/zip' length 1645590 bytes (1.6 Mb) opened URL downloaded 1.6 Mb package 'multtest' successfully unpacked
2013 Aug 09
1
a fast table() for the 1D case
Hi, table1D() below can be up to 60x faster than base::table() for the 1D case. Here are the detailed speedups compared to base::table(). o With a logical vector of length 5M: 11x faster (or more if 'useNA="always"') o With factor/integer/numeric/character of length 1M and 9 levels (or 9 distinct values for non-factors):
2018 May 16
2
Dispatch mechanism seems to alter object before calling method on it
On 05/15/2018 09:13 PM, Michael Lawrence wrote: > My understanding is that array (or any other structure) does not > "simply" inherit from vector, because structures are not vectors in > the strictest sense. Basically, once a vector gains attributes, it is > a structure, not a vector. The methods package accommodates this by > defining an "is" relationship
2017 May 03
2
stopifnot() does not stop at first non-TRUE argument
Not sure why the performance penalty of nonstandard evaluation would be more of a concern here than for something like switch(). If that can't/won't be fixed, what about fixing the man page so it's in sync with the current behavior? Thanks, H. On 05/03/2017 02:26 AM, peter dalgaard wrote: > The first line of stopifnot is > > n <- length(ll <- list(...)) > >
2010 Jun 03
1
named empty list
Hi, I just realized that a named empty list is displayed the same way as an empty list: > list(aa=2:5)[0] list() > list() list() For empty atomic vectors, the print method makes the difference: > c(aa=3L)[0] named integer(0) > integer(0) integer(0) Maybe lists could do that too? Thanks, H. > sessionInfo() R version 2.12.0 Under development (unstable)