| evaluate_tna_estimation | R Documentation |
Draws a transition system per replication, simulates sequences from it, fits
each estimator in models, and scores the fitted edges against the
generating probabilities. Fitted weights are row-normalized before the
comparison, so estimators on different weight scales are all read as
transition probabilities.
evaluate_tna_estimation(
repetitions = 100L,
n = 200L,
chain_length = 25L,
n_states = 6L,
models = c("tna", "ftna", "ctna", "atna"),
concentration = 1,
diagonal_concentration = 0,
missing_tail = c(0L, 5L),
threshold = 0,
seed = NULL,
...
)
repetitions |
Number of simulation replications. A single positive whole
number, defaulting to |
n |
Number of sequences per replication. A single whole number of at
least 2, defaulting to |
chain_length |
Sequence length. A single whole number of at least 2,
defaulting to |
n_states |
Number of states. A single whole number of at least 2,
defaulting to |
models |
TNA estimators to evaluate. A character vector of at least one
of |
concentration, diagonal_concentration |
Transition-system parameters
passed to |
missing_tail |
Trailing missing positions passed to
|
threshold |
Absolute weight threshold above which an edge counts as
present, in both the agreement and the recovery metrics. A single
non-negative number, defaulting to |
seed |
Optional base seed. A single number, or |
... |
Arguments passed to |
A simulab_sim base data.frame with one row per replication and
model, holding iteration, model, the compare_networks() agreement
metrics and the evaluate_edge_recovery() summary. Components: truth,
the generating probabilities with columns iteration, from, to and
weight; and estimated_edges, the row-normalized fitted edges with
columns iteration, model, from, to and weight.
if (requireNamespace("tna", quietly = TRUE)) {
evaluate_tna_estimation(
repetitions = 2, n = 30, chain_length = 10, n_states = 3,
models = "tna", seed = 1
)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.