Displaying 20 results from an estimated 2000 matches similar to: "several bugs (PR#918) lists and matrices"
2001 Sep 27
1
Problem with merge() (PR#1102)
I have encountered a problem with merge() that appears to be a bug.
Here's an example to illustrate it.
> tmp1 <- data.frame(a=letters[1:3],b=LETTERS[2:4],x=1:3)
> tmpa <- expand.grid(a=letters[1:4],b=LETTERS[1:4])
> tmpm.1 <- merge(tmpa,tmp1)
> tmpm.2 <- merge(tmp1,tmpa)
Error in "names<-.default"(*tmp*, value = vnames) :
names attribute must
2001 Apr 23
1
several bugs (PR#918)
# Your mailer is set to "none" (default on Windows),
# hence we cannot send the bug report directly from R.
# Please copy the bug report (after finishing it) to
# your favorite email program and send it to
#
# r-bugs@r-project.org
#
######################################################
1. as.numeric behaves differently in R than in S and I think this
shows a bug in how S3
2001 Dec 04
3
factorial() not here (PR#1194)
Version 1.3.1 (2001-08-31)
factorial() is not in R. It is in S-Plus with the definition
factorial <- function(n) gamma(n + 1)
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not
2010 Jan 16
1
order() fails on a chr object of class "AsIs" with "\265" in it
Here's an example (session info at the end).
> tmpv <- c('\265g/L','Bq/L')
> order(tmpv)
[1] 2 1
> tmpv <- I(tmpv)
> order(tmpv)
Error in if (xi > xj) 1L else -1L : missing value where TRUE/FALSE needed
> foov <- gsub('\265','',tmpv)
> order(foov)
[1] 2 1
> str(tmpv)
Class 'AsIs' chr [1:2] "\265g/L"
2001 Dec 11
4
crash bug in get("function.name")() (PR#1211)
R : Copyright 2001, The R Development Core Team
Version 1.3.1 (2001-08-31)
> tmp <- factor(1:3)
> get("print.factor")(tmp)
[1] 1 2 3
Levels: 1 2 3
> print.a <- function(x,...) {
+ print("this is a")
+ NextMethod("print", x, quote = FALSE, right = TRUE, ...)
+ }
>
> get("print.a")
function(x,...) {
print("this is a")
2008 May 30
1
NAMESPACE & methods guidance, please
My conception of how NAMESPACE and methods in R-2.7.0 resolved a
generic 'func' to a func-method was to search as follows:
In 2.7.0:
func -->
NAMESPACE, including Imports: (and other details) -->
.GlobalEnv, and eventually Depends: since these are on search()
In R-devel it seems like
func -->
NAMESPACE, including Imports: (and other details) -->
?? but not
2008 Feb 17
1
NAMESPACEs and S4 classes
I'd like to have two packages with S4 classes with the same name but
different implementation. To that end I create a package tmpA with
setClass("A",
representation=representation(
x="numeric"),
sealed=TRUE)
setClass("B",
representation=representation(
x="numeric"))
B <- function(...)
2008 Sep 10
1
Computation of contour values - Speeding up computation
Dear R useRs,
i have the following code to compute values needed for a contour plot
############################################################
"myContour" <- function(a, b, plist, veca, vecb, dim)
{
tmpb <- seq(0.5 * b, 1.5 * b, length=dim)
tmpa <- seq(0.5 * a, 1.5 * a, length=dim)
z <- matrix(0, nrow=dim, ncol=dim)
for(i in 1:dim)
{
for(j in 1:dim)
2011 Aug 01
2
Errors, driving me nuts
Greetings all,
I am getting this error that is driving me nuts... (not a long trip, haha)
I have a set of files and in these files I want to calculate ttests on
rows 'compareA' and 'compareB' (these will change over time there I
want a variable here). Also these files are in many different
directories so I want a way filter out the junk... Anyway I don't
believe that this is
2003 Mar 02
2
bug in bwplot (PR#2595)
> tmp <- data.frame(y=rnorm(12), g=factor(rep(1:2,6)))
> bwplot(g ~ y, data=tmp)
Error in segments(x1 = structure(c(-1.68373790592731, 0.159038997376781, :
Argument "x0" is missing, with no default
> version
_
platform i386-pc-mingw32
arch i386
os mingw32
system i386, mingw32
status
major 1
2002 Aug 07
1
ESS assigns .Last.value to the wrong place in R
I repeat my emails of 11/15/01 and 2/26/02, since it looks like this ESS bug is
still not fixed in ESS 5.1.23, and I think some resolution is needed.
When help() is invoked, ESS makes a copy of .Last.value in the .GlobalEnv,
which is *not* where R normally stores it (R stores it in package:base).
When this copy becomes stale it leads to wrong answers. The bug is in
essd-r.el, lines 63-64:
2008 Oct 08
1
follow up on "[Rd] NAMESPACE & methods guidance, please" ( http://tolstoy.newcastle.edu.au/R/e4/devel/08/06/1901.html )
This is a follow-up on the discussion originally posted on the R-devel list ( http://tolstoy.newcastle.edu.au/R/e4/devel/08/06/1901.html ), as I have encountered the exact same issue mentioned in Martin's email. Here is a simplified version of my problem:
##=================================================================
## I created a package, say, "tmpA", with a NAMESPACE with
2006 Nov 23
2
loading libraries on MPI cluster
Dear R-users,
we are using library(snow) for computation on a linux cluster with RMPI.
We have a problem with clusterEvalQ: after launching clusterEvalQ it seems
loading the required library on each node but if we type a function
belonging to the loaded package R doesn't find it.
> library(snow)
# making cluster with 3 nodes
> cl <- makeCluster(3, type = "MPI")
Loading
2005 Apr 21
1
Installing packages from source code
Hi everybody,
I have trouble in installing packages from source code by following Section
5.1 in manual R-admin.pdf . I am using R 2.1.0 and Win NT.
Following the Windows toolset section in the manual, I download the tool
set package from: http://www.murdoch-sutherland.com/Rtools/tools.zip
and unzip under C:\tools
I also downloaded Perl (Windows Port) and installed it.
2003 Mar 04
3
question on latticeParseFormula (PR#2602)
This feels like inconsistent behavior. latticeParseFormula works the
way I anticipated for factor, but not for ordered. I want the
behavior I see with tmp2, but not with tmp. My next step is to use
the right.name to isolate the tmp2[,c("a","b")] columns.
tmp <- data.frame(y=(1:12)+.1,
a=factor(rep(1:3,4)),
b=ordered(rep(1:4,
2011 Aug 12
1
install packages from intranet
Hi,
I'm new to R. Apologies if this is a simple query, I've searched the mailing lists and docs but can't find a solution to my problem.
I'm trying to make some packages available on our intranet. During development the 'intranet' is a webserver running on localhost.
* When I call "install.packages" I get a mesage about not being able to access 'index
2003 Oct 21
5
do.call() and aperm()
Hi everyone
I've been playing with do.call() but I'm having problems understanding it.
I have a list of "n" elements, each one of which is "d" dimensional
[actually an n-by-n-by ... by-n array]. Neither n nor d is known in
advance. I want to bind the elements together in a higher-dimensional
array.
Toy example follows with d=n=3.
f <-
2005 Oct 21
1
Generalised rbind/cbind
Dear list,
Is there a generalised form of rbind/cbind for combining
matrices/arrays into higher-D structures? ie. if I have:
a <- matrix(2,2,2)
b <- matrix(3,2,2)
how can I get
array(rep(c(3,2), each=4), c(2,2,2))
?
It seems like this would be the job of a generalised abind function:
abind(a,b, along=1) == rbind(a,b)
abind(a,b, along=2) == cbind(a,b)
abind(a,b, along=3)
2000 Mar 17
1
optim: problem with additional arguments (PR#493)
The R function "optim" fails when a function requires additional
arguments, if the option "hessian=T" is specified. I am using R Version
1.0.0 on Windows 98.
Here is an example of the Rosenbrock Banana function from the optim help
example, with the function and gradient modified to take an additonal
argument. Note that the call to optim works fine unless a hessian is
2011 Jan 20
1
syntax for a list of components from a list
I'm attempting to generalise a function that reads individual list components, in this case they are matrices, and converts them into 3 dimensional array. I can input each matrix individually, but want to do it for about 1,000 of them ...
This works
array2 <- abind(list1[[1]],list1[[2]],list1[[3]],along=3)
This doesn't
array2 <- abind(list1[[1:3]],along=3)
This doesn't either