Hello folks! For once I write a post in English... it actually corresponds to the vignette of a small package (flowrpowr) I wrote to celebrate my being back to work ;-). You might find that package quite superfluous, but my visual brains and I have been hoping for something like this for a while now :-). You can install this package from [my github repo], and I hope you will find it useful, fun, and not too flawed...
The convention for naming functions and functions’ arguments of packages in the tidyverse is such that these functions and arguments’ names help understand their purpose and construction.
#options(download.file.method = "libcurl") #devtools::install_github("lvaudor/flowrpowr") #devtools::install_github("thomasp85/ggforce") library(flowrpowr)
flowrpowr package exploits that characteristic to produce graphs which intend to facilitate the exploration and understanding of a package’s content and of functions’ arguments.
Let’s explore, for instance, the
This graph lets us understand that many functions in this package will start with prefix “str_” and then lists all possible combinations (all functions of type
str_*(), for instance
str_*_*() -for instance
In the case of
stringr the common root
str_for many functions makes a tree-like layout easily readable:
Some packages gather many functions, which makes it preferable to display only some functions in the graph. For instance, the
ggraph package is quite big to be displayed in a single graph:
So it might be useful to display only part of the graph making use of an element of interest. For instance, if I’m looking, specifically, for some function regarding the edges:
It is also possible to explore the arguments to one or several functions. Examining several functions at once help understand the arguments they have in common and the ones that are specific to each.
A few functions mean a few distinct roots, which might be well suited to a Sugiyama layout: