[Rd] 'CanMakeUseOf' field [was ".. Add 'fields' argument ..]

McGehee, Robert Robert.McGehee at geodecapital.com
Tue Aug 29 16:31:03 CEST 2006


CanUse?

If the 'Suggests' field "lists packages that are not necessarily needed"
(Writing R Extensions), then why is the user required to have the
package installed to pass R CMD check? Likewise, if a CanMakeUseOf field
is added, then why would one choose to use Suggests at all? That is, is
there an advantage to requiring that the user have a package available
(to pass R CMD check) even if they do not need to load it to get
functionality?

I occasionally write functions of the form:
	if (require(pkg)) optimizedCode() else regularCode()
which works better for users who have installed additional packages, but
does not fail if the user has not. Such a field would be a nice addition
to inform users that getting an additional package might be
advantageous.

Cheers,
Robert

-----Original Message-----
From: r-devel-bounces at r-project.org
[mailto:r-devel-bounces at r-project.org] On Behalf Of Martin Maechler
Sent: Tuesday, August 29, 2006 10:13 AM
To: Paul Gilbert
Cc: r-devel at stat.math.ethz.ch
Subject: Re: [Rd] 'CanMakeUseOf' field [was ".. Add 'fields' argument
..]

>>>>> "PaulG" == Paul Gilbert <pgilbert at bank-banque-canada.ca>
>>>>>     on Tue, 29 Aug 2006 09:55:09 -0400 writes:

    PaulG> Martin Maechler wrote:
    >> ...
    >> 
    >> The idea was a field related to but weaker than 'Suggests' :
    >> Something like
    >> 'canMakeUseOf: <pkg1> [, <pkg2>, ... ]
    >> which is *not* used in any QA/QC checking, but is purely
    >> informative: If <pkg1> is require()able, then some examples may
    >> look nicer, a function may provide another feature, etc, etc.
    >> Alternatives to 'canMakeUseOf' would have been
    >> 'isHappilyCoworkingWith' ....
    >> 
    >> What do you (R-devel listeners) think about the idea?

    PaulG> I still like this idea.  I prefer 'canMakeUseOf' to 
    PaulG> 'isHappilyCoworkingWith'  mainly because it seems less
ambiguous.

Thanks, Paul.
As you may have guessed I should have put a  " :-) "  beside the
'isHappily...' .

Of course, even 'CanMakeUseOf' {we should capitalize the first letter}
is rather too long, but before finding the proper term, we should
agree on usefulness of such a new field.
Apart from the use of package authors {some could note that
other packages make use of theirs, without already depending on
or suggesting them}, it's one of those fields that should help
in the future to explore (e.g. cluster or neighborhood-graph)
the growing high-dimensional space of R packages.

Martin

______________________________________________
R-devel at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel




More information about the R-devel mailing list