Re: [Rd] conditionally import a namespace?

2008-10-31 Thread Felix Andrews
2008/10/31 Duncan Murdoch [EMAIL PROTECTED]: On 10/30/2008 10:44 AM, Duncan Murdoch wrote: On 10/30/2008 10:15 AM, Martin Maechler wrote: FA == Felix Andrews [EMAIL PROTECTED] on Thu, 30 Oct 2008 17:40:17 +1100 writes: FA Dear R-devel, FA I have a problem defining the

Re: [Rd] conditionally import a namespace?

2008-10-30 Thread Martin Maechler
FA == Felix Andrews [EMAIL PROTECTED] on Thu, 30 Oct 2008 17:40:17 +1100 writes: FA Dear R-devel, FA I have a problem defining the dependencies for a package. FA My package (latticist, not yet released) Suggests RGtk2, but FA specifically does not require it. If RGtk2 is

Re: [Rd] conditionally import a namespace?

2008-10-30 Thread Jeff Ryan
Or something along the lines of: Suggests: RGtk2 f - function (x, ...) { stopifnot(package:RGtk2 %in% search() || require(RGtk2, quietly = TRUE)) # do Rgtk2 stuff here } Jeff On Thu, Oct 30, 2008 at 9:15 AM, Martin Maechler [EMAIL PROTECTED] wrote: FA == Felix Andrews [EMAIL

Re: [Rd] conditionally import a namespace?

2008-10-30 Thread Duncan Murdoch
On 10/30/2008 10:15 AM, Martin Maechler wrote: FA == Felix Andrews [EMAIL PROTECTED] on Thu, 30 Oct 2008 17:40:17 +1100 writes: FA Dear R-devel, FA I have a problem defining the dependencies for a package. FA My package (latticist, not yet released) Suggests RGtk2, but FA

Re: [Rd] conditionally import a namespace?

2008-10-30 Thread Duncan Murdoch
On 10/30/2008 10:44 AM, Duncan Murdoch wrote: On 10/30/2008 10:15 AM, Martin Maechler wrote: FA == Felix Andrews [EMAIL PROTECTED] on Thu, 30 Oct 2008 17:40:17 +1100 writes: FA Dear R-devel, FA I have a problem defining the dependencies for a package. FA My package

Re: [Rd] conditionally import a namespace?

2008-10-30 Thread Gabor Grothendieck
I noticed there is also an experimental interface that can be used from R (as opposed to the NAMESPACE file). Can't tell from docs whether it allows conditionals: ?.Import On Thu, Oct 30, 2008 at 10:44 AM, Duncan Murdoch [EMAIL PROTECTED] wrote: On 10/30/2008 10:15 AM, Martin Maechler wrote: