By default, this compares a model's tags to the tags on any of its "parent"
models. A parent model is any model referenced in the relevant model's
based_on field. The bbi_model dispatch can optionally take a second
model, in which case it will compare the first model to the second model,
ignoring the based_on field entirely.
Arguments
- .bbi_object
The object to compare. Could be a
bbi_{.model_type}_modelobject or a tibble of classbbi_run_log_df.- .mod2
If a
bbi_{.model_type}_modelobject is passed, compare.bbi_objectto.mod2. If.mod2 = NULL, the default, compare the.bbi_objectmodel to any models in itsbased_onfield. Only valid forbbi_modelmethod.If
TRUE, the default, will print a nicely formatted version of the returned list to the console. Only valid forbbi_modelmethod.- ...
arguments passed through to methods. (Currently none.)
- .log_df
a
bbi_run_log_dftibble (the output ofrun_log())
Value
In all cases:
tags_addedcontains any tags that are on the relevant model, but not on any of the models it is based on.tags_removedcontains any tags that are on at least one of the models it is based on, but not on the relevant model.
tags_diff.bbi_model() invisibly returns a list with two elements:
tags_added and tags_removed. The list is returned invisibly because, by
default, a nicely formatted version of the same information is printed to the
console. User can pass .print = FALSE to turn this off.
tags_diff.bbi_run_log_df() returns a named list of lists, with one
element for each row in the input tibble, with the name corresponding to the
value in the run column for that row. Each element of the list will contain
the two-element list returned from tags_diff.bbi_model() (described above)
for the relevant model.
add_tags_diff() returns the same tibble that was passed to it, but
it, but with two additional columns tags_added and tags_removed
appended.
