On 16/05/2017 7:34 AM, Thierry Onkelinx wrote:
Try adding requireNamespace("ggplot2") in the function that rely on ggplot2.

That's not enough, even though it might fool the test (I haven't checked). Those functions need to condition on the result, i.e. something like

if (requireNamespace("ggplot2")) ggplot2::ggplot()
else  ... (optional warning that you need it) ...

Duncan Murdoch


ir. Thierry Onkelinx
Instituut voor natuur- en bosonderzoek / Research Institute for Nature and
Forest
team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance
Kliniekstraat 25
1070 Anderlecht
Belgium

To call in the statistician after the experiment is done may be no more
than asking him to perform a post-mortem examination: he may be able to say
what the experiment died of. ~ Sir Ronald Aylmer Fisher
The plural of anecdote is not data. ~ Roger Brinner
The combination of some data and an aching desire for an answer does not
ensure that a reasonable answer can be extracted from a given body of data.
~ John Tukey

2017-05-16 13:22 GMT+02:00 Jonathon Love <j...@thon.cc>:

yes, sorry, crucial piece of information i forgot to mention.

ggplot2 *is* in suggests.

with thanks

jonathon


On 16/5/17 21:21, Thierry Onkelinx wrote:
Dear Jonathon,

Is ggplot2 listed in the DESCRIPTION file? It needs to be at least in
the Suggests:

Best regards,

Thierry

ir. Thierry Onkelinx
Instituut voor natuur- en bosonderzoek / Research Institute for Nature
and Forest
team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance
Kliniekstraat 25
1070 Anderlecht
Belgium

To call in the statistician after the experiment is done may be no
more than asking him to perform a post-mortem examination: he may be
able to say what the experiment died of. ~ Sir Ronald Aylmer Fisher
The plural of anecdote is not data. ~ Roger Brinner
The combination of some data and an aching desire for an answer does
not ensure that a reasonable answer can be extracted from a given body
of data. ~ John Tukey

2017-05-16 13:12 GMT+02:00 Jonathon Love <j...@thon.cc
<mailto:j...@thon.cc>>:

    hi,

    i'm receiving failures on the winbuilder, with it complaining that
    ggplot2 can not be found:

    https://win-builder.r-project.org/incoming_pretest/170516_
125043_jmvcore_055/00install.out
    <https://win-builder.r-project.org/incoming_pretest/
170516_125043_jmvcore_055/00install.out>

    now there are some mentions of ggplot2 in our code (but none in
    our NAMESPACE, we always use the full namespace when calling
    functions: `ggplot2::ggplot()`), allowing people to pass in
    ggplot2 themes and for them to be handled correctly, but packages
    that build on jmvcore don't *need* to use ggplot2. so we've been
    able to avoid adding it as an import, which is great, because
    ggplot2 brings quite a few dependencies.

    our code works as intended, passes all tests with `R CMD check
    --as-cran jmvcore`, etc.

    however the win-builder is pinging us.

    is there a way around this?

    with thanks

    jonathon

    ______________________________________________
    R-package-devel@r-project.org
    <mailto:R-package-devel@r-project.org> mailing list
    https://stat.ethz.ch/mailman/listinfo/r-package-devel
    <https://stat.ethz.ch/mailman/listinfo/r-package-devel>




        [[alternative HTML version deleted]]

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


        [[alternative HTML version deleted]]

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


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

Reply via email to