rev_args | R Documentation |
From a package, get all the default arguments for the functions of said package. Then check how many times each argument is used and whether the default value for the argument is consistent across all functions where it's used. This function also returns a matrix indicating each function where the arguments are used.
rev_args(path = ".", exported_only = FALSE)
path |
Name of a source R package tar archive file, or path to the folder of an R package. |
exported_only |
Logical. Whether to check only the exported functions or all the functions detected by rev_calls. or all the functions detected by rev_calls. |
A two element list with arg_df
and arg_map
.
The arg_df
is a data.frame with one element per argument that
has the name of the argument, the number of functions where it's used,
whether the default is consistent across all functions and percent
of consistency (based on the first appearance of the argument).
arg_map
is a logical matrix with the functions in the rows and the
arguments in the columns. It specifies which functions use which arguments.
Leonardo Collado-Torres https://github.com/lcolladotor
# TO inspect a package at your working directory use `path = "."` rev_args(pkginspector_example("viridisLite"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.