Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #149
The idea of this PR is the reduce a little further the clutter while remaining accurate.
Here is an example with dplyr, a package with a lot of dependencies.
The basic plot is quite unreadable because it shows too much:
The situation improves if suggested packages are turned off:
But one could argue, do we really need here to show e.g. pkgconfig which is only on indirect dependencies (imported by tibble, which is itself imported by dplyr).
What I did was thus to refine the internal call to
tools::package_dependencies()
so as to exploit the argument it contains calledrecursive
. It was hard-coded asTRUE
but now the user can control it:Note that contrary to the original argument
recursive
intools::package_dependencies()
which allows for both logical or character vector input, I restricted the use to a logical only. I explored the alternative but it would lead to quite a lot of changes in the code.I paid attention to update the package examples, tests, news and description.
R CMD check does not complain about anything on my system.