Closed eribul closed 4 years ago
Review: Thank you for the suggestion! I agree that this convention can be useful. I do think it is almost as simple to use autocomplete with the coder::
prefix instead of coder_
, however. The difference is just one additional key stroke :-) and I would prefer shorter names without this redundancy coder::coder_xxx
.
This naming convention is also discussed in the Tidyverse design guide, section 5.2 (https://design.tidyverse.org/function-names.html#function-families) with the following paragraph:
Not sure about common prefixes for a package. Works well for stringr (esp. with stringi), forcats, xml2, and rvest. But there’s only a limited number of short prefixes and I think it would break down if every package did it.
An alternative for function naming is to have a common prefix for functions, e.g., coder_classify, coder_categorize, coder_index, coder_codify, coder_visualize. This has both the advantage of ensuring it doesn't overlap with other packages and making it easy to find codify-related functions with autocomplete. But that's just a suggestion.