Re: [Rd] Overriding S4 methods in an installed package

2007-08-18 Thread Allen McIntosh
Duncan Murdoch wrote: > I think you can set the environment of your method to see the package > internals. Those internals won't see your method, though. > > To do this, you'd do something like > > newfoo <- function(obj , x, y) { new definition } > environment(newfoo) <- environment(foo) # or

Re: [Rd] [R] Suspected memory leak with R v.2.5.x and large matrices with dimnames set

2007-08-18 Thread Luke Tierney
Seth's analysis is correct. R does return what it can to the malloc system by calling free. When and how much memory malloc releases back to the OS varies with OS and malloc system and also depends on the sizes of allocations. R curently allocates its memory for small objects in pages of about 2K

Re: [Rd] Overriding S4 methods in an installed package

2007-08-18 Thread Duncan Murdoch
Allen McIntosh wrote: > Seth Falcon wrote: > >> Allen McIntosh <[EMAIL PROTECTED]> writes: >> >>> Is it possible to override S4 methods in an installed package? >>> The naive >>> library("pkg") >>> setMethod("foo", signature(obj = "bar"), >>> function(obj , x, y) { new definition }

Re: [Rd] Overriding S4 methods in an installed package

2007-08-18 Thread Allen McIntosh
Seth Falcon wrote: > Allen McIntosh <[EMAIL PROTECTED]> writes: >> Is it possible to override S4 methods in an installed package? >> The naive >> library("pkg") >> setMethod("foo", signature(obj = "bar"), >> function(obj , x, y) { new definition } >> , where="package:pkg") >> results i

Re: [Rd] [R] Suspected memory leak with R v.2.5.x and large matrices with dimnames set

2007-08-18 Thread Seth Falcon
Hi Peter, Peter Waltman <[EMAIL PROTECTED]> writes: >Admittedly, this may not be the most sophisticated memory profiling >performed, but when using unix's top command, I'm noticing a notable >memory leak when using R with a large matrix that has dimnames >set. I'm not sure I

Re: [Rd] Overriding S4 methods in an installed package

2007-08-18 Thread Seth Falcon
Allen McIntosh <[EMAIL PROTECTED]> writes: > Is it possible to override S4 methods in an installed package? > The naive > > library("pkg") > setMethod("foo", signature(obj = "bar"), > function(obj , x, y) { new definition } > , where="package:pkg") > > > results in the error > > Erro

[Rd] match.arg bug or documentation error (PR#9859)

2007-08-18 Thread gunter . berton
There is either a bug or undocumented feature (afaics) in match.arg that requires the length of the arg argument to be no longer than the length of the choices argument even when several.ok is TRUE. Here is a reproducible example: first: > sessionInfo() R version 2.5.0 Patched (2007-04-26 r4132

[Rd] Overriding S4 methods in an installed package

2007-08-18 Thread Allen McIntosh
Is it possible to override S4 methods in an installed package? The naive library("pkg") setMethod("foo", signature(obj = "bar"), function(obj , x, y) { new definition } , where="package:pkg") results in the error Error in setMethod("foo", signature(obj = "bar"), function(obj, :

[Rd] Hedge Fund Job Opening

2007-08-18 Thread Franklin Parlamis
Hi all. I've been lurking and posting on this list for a few years now. Prior to that, I managed the US Convertible Arbitrage portfolio for Amaranth Advisors. I recently agreed to manage a similar portfolio for a different hedge fund and am looking for someone to join me, essentially as the