Re: [Rd] Functions that write functions in R packages

2007-02-23 Thread Gabor Grothendieck
Not sure what the setup is here but if the objects are intended to be proto objects then the accessor functions could be placed in the object itself (or in an ancestor object) rather than in the global environment. For example, this inserts a function get.v(.) into proto object p for each variable

[Rd] Depending on many packages: another best practice question

2007-02-23 Thread hadley wickham
Dear all, ggplot currently requires 13 packages (grid, reshape, RColorBrewer, proto, splines, MASS, Hmisc, boot, butler, hexbin, mapproj, quantreg, sm). Some of these are absolutely necessary (eg. proto), but most are used for one or two specific tasks (eg. boot is only used to get plogis, used f

Re: [Rd] How to override functions in namespaces?

2007-02-23 Thread Jeffrey J. Hallman
Prof Ripley, Thanks to both you and Duncan Murdoch, who replied with similar advice. Your suggestion to use get("askForString", pos = 1)() in my ssh() function does what I want whether package B is attached or not. Jeff Prof Brian Ripley <[EMAIL PROTECTED]> wrote: br> On Mon, 12 Feb 2007, [EMA

[Rd] Solved two problems with Cygwin

2007-02-23 Thread Kevin Wright
While installing software on a new computer, I thought I would try to use Cygwin to build an R package. (Note: NOT Ripley/Murdoch's Rtools). I uncovered and solved two issues, one of which appears to be identical to a problem previously reported (and unsolved) on this list. I offer this informat

[Rd] Formatting difftime objects

2007-02-23 Thread Jeffrey Horner
I like the new difftime functionality. Here's a dataframe of 5k run times: > r5k racedate totaltime pace mile 1 RUDOLPH 2004-12-03 19:00:00 27.76667 mins 8.937224 mins 3.106856 2 RUDOLPH 2005-12-02 18:30:00 25.28333 mins 8.137916 mins 3.106856 3

Re: [Rd] Functions that write functions in R packages

2007-02-23 Thread hadley wickham
On 2/23/07, Duncan Murdoch <[EMAIL PROTECTED]> wrote: > On 2/23/2007 11:05 AM, hadley wickham wrote: > > Dear all, > > > > Another question related to my ggplot package: I have made some > > substantial changes to the backend of my package so that plot objects > > can now describe themselves much

Re: [Rd] Functions that write functions in R packages

2007-02-23 Thread Duncan Murdoch
On 2/23/2007 11:05 AM, hadley wickham wrote: > Dear all, > > Another question related to my ggplot package: I have made some > substantial changes to the backend of my package so that plot objects > can now describe themselves much better. A consequence of this is > that a number of convenience

[Rd] Functions that write functions in R packages

2007-02-23 Thread hadley wickham
Dear all, Another question related to my ggplot package: I have made some substantial changes to the backend of my package so that plot objects can now describe themselves much better. A consequence of this is that a number of convenience functions that previously I wrote by hand, can now be wri

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Ramon Diaz-Uriarte
On Friday 23 February 2007 15:52, Marc Schwartz wrote: > In addition to Prof. Ripley's comments, which I wholeheartedly support, > I might point you to some additional tools, that enhance the use of > Emacs for coding. > > I am running Emacs (alpha version 23 from cvs source) under Linux and > whil

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Marc Schwartz
In addition to Prof. Ripley's comments, which I wholeheartedly support, I might point you to some additional tools, that enhance the use of Emacs for coding. I am running Emacs (alpha version 23 from cvs source) under Linux and while I do not do C, C++ or FORTRAN coding, these tools have dramatica

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Vincent Goulet
Le Vendredi 23 Février 2007 05:49, mel a écrit : > Dear all, > > I have to develop a (hopefully) small package for R in C++. > I didn't code in C++ for some years, and i'm now searching > for an adequate IDE for this task. > > Some of my criterions : not proprietary, not too heavy, > open to linux,

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Hin-Tak Leung
I don't know if ess runs under xemacs, but historically, xemacs (a fork of the emacs code) had windows support earlier than gnu emacs did, and obviously, it is still being worked on as the last version is December 2006. http://www.xemacs.org/Download/win32/ HTH mel wrote: > Dear all, > > I have

Re: [Rd] Bootstrapping stepAIC() with glm.nb()

2007-02-23 Thread Prof Brian Ripley
On Fri, 23 Feb 2007, Dimitris Rizopoulos wrote: > > - Original Message - From: "Prof Brian Ripley" > <[EMAIL PROTECTED]> > To: "Dimitris Rizopoulos" <[EMAIL PROTECTED]> > Cc: > Sent: Friday, February 23, 2007 1:40 PM > Subject: Re: [Rd] Bootstrapping stepAIC() with glm.nb() > > >> You di

Re: [Rd] Bootstrapping stepAIC() with glm.nb()

2007-02-23 Thread Dimitris Rizopoulos
- Original Message - From: "Prof Brian Ripley" <[EMAIL PROTECTED]> To: "Dimitris Rizopoulos" <[EMAIL PROTECTED]> Cc: Sent: Friday, February 23, 2007 1:40 PM Subject: Re: [Rd] Bootstrapping stepAIC() with glm.nb() > You did not say what the problem was! > > But you are asking that an ob

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Henric Nilsson (Public)
Den Fr, 2007-02-23, 11:49 skrev mel: > Dear all, > > I have to develop a (hopefully) small package for R in C++. > I didn't code in C++ for some years, and i'm now searching > for an adequate IDE for this task. > > Some of my criterions : not proprietary, not too heavy, > open to linux, not java ga

Re: [Rd] Bootstrapping stepAIC() with glm.nb()

2007-02-23 Thread Prof Brian Ripley
You did not say what the problem was! But you are asking that an object which is not in scope (index) be found a few levels down. You should be able to fix this by substituting in the values in fn. Here is one way: up.obj <- update(object, data = data[index[, i], ]) Call <-

[Rd] Bootstrapping stepAIC() with glm.nb()

2007-02-23 Thread Dimitris Rizopoulos
Dear all, I would like to Boostrap the stepAIC() procedure from package MASS for variety of model objects, i.e., fn <- function(object, data, B = 2){ n <- nrow(data) res <- vector(mode = "list", length = B) index <- sample(n, n * B, replace = TRUE) dim(index) <- c(n, B) for (

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread mel
Thanks for those first answers. Indeed i forgot to precise that i'm currently working on windows (but would like to be able to evolve to linux). __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Prof Brian Ripley
You seem to mention both Linux and Windows. Emacs and XEmacs are both stable on both platforms, and I think most R developers use an emacs or vi variant for all their programming. I would not call emacs an IDE, but the main thing I find useful is to have a language-aware editor (syntax highlig

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Ramon Diaz-Uriarte
On Friday 23 February 2007 11:49, mel wrote: > Dear all, > > I have to develop a (hopefully) small package for R in C++. > I didn't code in C++ for some years, and i'm now searching > for an adequate IDE for this task. > > Some of my criterions : not proprietary, not too heavy, > open to linux, not

Re: [Rd] IDE for R C++ package writing ?

2007-02-23 Thread Sean Davis
On Friday 23 February 2007 05:49, mel wrote: > Dear all, > > I have to develop a (hopefully) small package for R in C++. > I didn't code in C++ for some years, and i'm now searching > for an adequate IDE for this task. > > Some of my criterions : not proprietary, not too heavy, > open to linux, not

[Rd] IDE for R C++ package writing ?

2007-02-23 Thread mel
Dear all, I have to develop a (hopefully) small package for R in C++. I didn't code in C++ for some years, and i'm now searching for an adequate IDE for this task. Some of my criterions : not proprietary, not too heavy, open to linux, not java gasworks, still maintained, etc After looking on sev

Re: [Rd] text.rpart for the "class" method doesn't act on label="yprob"

2007-02-23 Thread Prof Brian Ripley
Not sure why this on R-devel! Nobody has contacted the maintainer, as asked by the posting guide. I've wondered about this in the past. It seems the argument was dropped in rpart3, but the help was not changed. It is checked but not used. On Wed, 21 Feb 2007, Robert King wrote: Hello Al