Hi,
> gctorture(TRUE)
> setGeneric("foo", function(x, y) standardGeneric("foo"))
[1] "foo"
> setMethod("foo", c("ANY", "ANY"),
+ function(x, y) cat("calling foo,ANY,ANY method\n")
+ )
Error: protect(): protection stack overflow
Sorry this is something I already reported one week
In fact reg.finalizer() looks like a dangerous feature.
If the finalizer itself triggers (implicitely or
explicitely) garbage collection, then bad things happen.
In the following example, garbage collection is triggered
explicitely (using R-2.9.0):
setClass("B", representation(bb="environment
Hi,
I can't get the non-abbreviated class names of the
rows and the cols of the Adjacency Matrix:
setClass("ClassWithALongName")
setClass("SubclassOfClassWithALongName",
contains="ClassWithALongName")
Trying all possible values for 'abbreviate' (with R-2.9.0):
classesToAM("SubclassOf
Hi,
When a method is not defined for an object, you
expect to get an error. But this is not the case for
"names<-". You can use "names<-" on any S4 object: it
will remain silent, giving you the impression that it
actually did something:
setClass("A", representation(vals="numeric"))
setMethod
Hi,
According to its man page, callNextMethod() (called with
no argument) should call the next method "with the arguments
to the current method passed down to the next method".
But, for the "[[" and "[" generics (primitives), the argument
after the dots doesn't seem to be passed down:
setClass("
Hi,
Trying to compile one of the latest snapshot tarballs of R-devel gives
me the following error (64-bit openSUSE 10.3):
...
make[2]: Entering directory
`/loc/home/biocbuild/bbs-2.4-bioc/R/src/library/Recommended'
make[2]: *** No rule to make target `VR.ts', needed by
`stamp-recommende
Quoting Prof Brian Ripley <[EMAIL PROTECTED]>:
What platform?
64-bit openSUSE Linux
[EMAIL PROTECTED]:~> uname -a
Linux george1 2.6.22.12-0.1-default #1 SMP 2007/11/06 23:05:18 UTC
x86_64 x86_64 x86_64 GNU/Linux
R version 2.8.0 Under development (unstable) (2008-07-07 r46046)
We've see
Hi,
I need to link mypackage to 2 other packages so I can call
some C functions defined in these 2 packages from mine.
I've tried
Depends: packageA, packageB
LinkingTo: packageA, packageB
as suggested by the "5.4 Registering native routines" section
of the "Writing R Extensions" manual but t
Hi Gabor,
Quoting Gabor Grothendieck <[EMAIL PROTECTED]>:
> The problem of promises not being evaluated in
> lists has been discussed before.
>
> I think its fixed in the development version of R. See
> r44139 on Jan 24, 2008 in http://developer.r-project.org/R.svnlog.2007
>
I'm using R-devel
Hi,
If needed, lapply() tries to convert its first argument into a list
before it starts doing something with it:
> lapply
function (X, FUN, ...)
{
FUN <- match.fun(FUN)
if (!is.vector(X) || is.object(X))
X <- as.list(X)
.Internal(lapply(X, FUN))
}
But in practice,
Hi,
Any idea why S4 doesn't allow slots of type "double"?
> setClass("A", representation(a="double"))
Error in makePrototypeFromClassDef(properties, ClassDef, immediate, where) :
in making the prototype for class "A" elements of the prototype failed to
match the corresponding slot class:
Hi,
?pairlist gives no explanation about what exactly is the difference
between a pairlist and a list (except that a pairlist of length 0
is 'NULL'). So, what's a pairlist?
class(.Options)
[1] "pairlist"
Some strange things about the "pairlist" type:
> showClass("pairlist")
Error in getClas
Hi,
Thanks to both for your answers!
Quoting Marc Schwartz <[EMAIL PROTECTED]>:
> On Thu, 2007-05-17 at 10:54 +0100, Prof Brian Ripley wrote:
> > To add to Marc's detective work. ?"[.data.frame" does say
> >
> > If '[' returns a data frame it will have unique (and non-missing)
> > r
Hi,
> dd <- data.frame(A=c("b","c","a"), B=3:1)
> dd
A B
1 b 3
2 c 2
3 a 1
> unlist(dd)
A1 A2 A3 B1 B2 B3
2 3 1 3 2 1
Someone else might get something different. It all depends on the
values of its 'stringsAsFactors' option:
> dd2 <- data.frame(A=c("b","c","a"), B=3:1, stringsAsFactors=F
Quoting hadley wickham <[EMAIL PROTECTED]>:
> On 3/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > Quoting [EMAIL PROTECTED]:
> > > In [.data.frame if you replace this:
> > >
> > > ...
> > > if (is.character(i)) {
> > > rows <- attr(xx, "row.names")
> > > i <- pmatch
Quoting [EMAIL PROTECTED]:
> In [.data.frame if you replace this:
>
> ...
> if (is.character(i)) {
> rows <- attr(xx, "row.names")
> i <- pmatch(i, rows, duplicates.ok = TRUE)
> }
> ...
>
> by this
>
> ...
> if (is.character(i)) {
> rows <- attr(xx
Hi Seth,
Quoting Seth Falcon <[EMAIL PROTECTED]>:
> Herve Pages <[EMAIL PROTECTED]> writes:
> > So apparently here extracting with dat[i, ] is 300 times faster than
> > extracting with dat[key, ] !
> >
> >> system.time(for (i in 1:100) dat["1", ])
> >user system elapsed
> > 12.680 0.396
Quoting Prof Brian Ripley <[EMAIL PROTECTED]>:
> This was fixed in SVN within a few hours. Tarballs are snapshots, please
> check SVN before reporting problems.
Thanks! I will check SVN before reporting problems with a tarball.
Just hope that nobody will get too upset if I'm reporting a problem
Hi,
On Windows, with last R-devel tarball (r40647) from
ftp://ftp.stat.math.ethz.ch/Software/R/R-devel_2007-02-04.tar.gz
I get the following build error:
E:\biocbld\bbs-2.0-bioc\R\src\gnuwin32> make
...
...
-- Making package utils
adding build stamp to DESCRIPTION
inst
Hi,
On my system, I get the following error message:
> big <- 2:(2**30)
Error: cannot allocate vector of size 0 Kb
Note the wrong "size 0 Kb" in the message!
Cheers,
H.
> sessionInfo()
R version 2.5.0 Under development (unstable) (2007-01-05 r40386)
i686-pc-linux-gnu
locale:
LC_CTYPE=en_
Hi Martin,
Thanks for taking the time to read me. Here is a followup,
it's rather long but hopefully not too long (and not too boring) ;-)
Quoting Martin Maechler <[EMAIL PROTECTED]>:
> Thank you, Herve,
>
> > "Herve" == Herve Pages <[EMAIL PROTECTED]>
> > on Fri, 02 Feb 2007 21:30:
Hi,
Man page for 'convolve' says:
conj: logical; if 'TRUE', take the complex _conjugate_ before
back-transforming (default, and used for usual convolution).
The complex conjugate of 'x', of 'y', of both?
In fact it seems that it takes the complex conjugate of 'y' only which
is OK
Hi Duncan,
This is even more confusing with a matrix:
> x <- matrix(5:-6, 3)
> x
[,1] [,2] [,3] [,4]
[1,]52 -1 -4
[2,]41 -2 -5
[3,]30 -3 -6
> x[invisible(2),3]
[1] -2
> x[2,invisible(3)]
> .Last.value
[1] -2
Tha
Hi,
On Windows, 'install.packages(,type="source")' displays the same output
than 'R CMD INSTALL --help' and doesn't install anything...
This is with R version 2.4.0 alpha (2006-09-06 r39158).
> install.packages('cat',type='source')
trying URL 'http://cran.cnr.Berkeley.edu/src/contrib/cat_0.0-6.
Hi lists,
Recently I needed to download a few R packages for Unix, Windows
and Mac OS X. The idea was to put them all together on a USB key
in order to be able to install them on systems without network connection.
It worked fine for the "src" and "win.binary" packages but I had the
following pr
Thomas Lumley wrote:
>On Fri, 6 Jan 2006, [EMAIL PROTECTED] wrote:
>
>
>
>>hi - in version 2.1 the command
>>
>>
>>
>>>-2^2
>>>
>>>
>>gives
>>
>>-4
>>
>>as the answer. (-2)^2 is evaluated correctly.
>>
>>
>
>So is -2^2. The precedence of ^ is higher than that of unary minus. It
26 matches
Mail list logo