You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suggest we move ggplot2 from Depends to Imports in DESCRIPTION, and, if necessary, update the code and vignettes (e.g., use extra ggplot2:: or library(ggplot2) due to it not being attached anymore when loading gsDesign).
This is for a few reasons:
Imports probably fits the use case better than Depends, considering plotting is not the main functionality of gsDesign. As indicated by r-pkgs:
Unless there is a good reason otherwise, you should always list packages in Imports not Depends. That's because a good package is self-contained, and minimises changes to the global environment (including the search path). The only exception is if your package is designed to be used in conjunction with another package. For example, the analogue package builds on top of vegan. It’s not useful without vegan, so it has vegan in Depends instead of Imports. Similarly, ggplot2 should really Depend on scales, rather than Importing it.
I'm always seeing the "Loading required package" message, sometimes with one of these "random tips":
library(gsDesign)
Loading required package: ggplot2
random tip here
They are good tips but kind of a distraction here.
Usage data tells a story. Today, ggplot2 has 451 reverse depends, 3067 reverse imports, and 1258 reverse suggests on CRAN. Among the 451 reverse depends, 100+ are apparently visualization/ggplot2 extension packages. Thus, with a 10:1 ratio, Imports is the much more mainstream usage when compared to Depends for ggplot2.
The text was updated successfully, but these errors were encountered:
I suggest we move ggplot2 from
Depends
toImports
inDESCRIPTION
, and, if necessary, update the code and vignettes (e.g., use extraggplot2::
orlibrary(ggplot2)
due to it not being attached anymore when loading gsDesign).This is for a few reasons:
Imports
probably fits the use case better thanDepends
, considering plotting is not the main functionality of gsDesign. As indicated by r-pkgs:They are good tips but kind of a distraction here.
Imports
is the much more mainstream usage when compared toDepends
for ggplot2.The text was updated successfully, but these errors were encountered: