variable_lineage | R Documentation |
This is an experimental feature that traces variable lineage through an injection of a ".uuid" attribute for each variable. Previous attempts at variable lineage were conducted using variable names and heuristics of known functions. This approach yields a more consistent lineage.
load_variable_lineage(
directory = here::here("blueprints"),
recurse = FALSE,
script = here::here("_targets.R")
)
filter_variable_lineage(
g,
variables = NULL,
tables = NULL,
mode = "all",
cutoff = -1
)
vis_variable_lineage(..., g = NULL, cluster_by_dataset = TRUE)
directory |
A folder containing blueprint scripts |
recurse |
Should this function recursively load blueprints? |
script |
Where the targets/drake project script file is located. Defaults to using targets. |
g |
An igraph object. This defaults to a graph loaded with load_variable_lineage. However, use this if you want to inspect subgraphs of the variable lineage. |
variables |
Character vector of patterns for variable names to
match. Note that each pattern is assumed to be disjoint (e.g. "if variable pattern
A or variable pattern B"), but if |
tables |
Character vector of patterns for table names to match. Note that
each pattern is assumed to be disjoint (e.g. "if table pattern A or table pattern B"),
but if |
mode |
Which sort of relationships to include. Defaults to "all" (includes both relations to the target node in the graph and from the target node in the graph). See igraph::all_simple_paths() for more details. |
cutoff |
The number of node steps to consider in the graph traversal for filtering. Defaults to -1 (no limit on steps). See igraph::all_simple_paths() for more details. |
... |
Arguments passed to load_variable_lineage |
cluster_by_dataset |
If |
To enable the variable feature, set options(blueprintr.use_variable_uuids = TRUE)
.
load_variable_lineage()
: Reads blueprintrs from folder to get variable lineage.
Returns an igraph of the variable lineage.
filter_variable_lineage()
: Filter for specific variables to include
in the lineage graph
vis_variable_lineage()
: Visualizes variable lineage with visNetwork.
Returns an interactive graph.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.