Learn R Programming

EpiModel (version 2.6.2)

dedup_cumulative_edgelist: Deduplicate a Cumulative Edgelist

Description

Merges overlapping spells for the same (head, tail) pair into a single row. Useful when concatenating cumulative edgelists across multiple simulations or sources, where the same partnership can appear in more than one segment. The reachability functions assume non-overlapping input.

Usage

dedup_cumulative_edgelist(el)

Value

A cumulative edgelist with no overlapping edges for the same (head, tail) pair.

Arguments

el

A cumulative edgelist with potentially overlapping edges.

See Also

as_cumulative_edgelist() for one source of duplicates; get_forward_reachable() / get_backward_reachable(), which expect non-overlapping input.

Other cumulative_edgelist: as_cumulative_edgelist(), get_cumulative_degree(), get_cumulative_edgelist(), get_cumulative_edgelists_df(), get_partners(), reachable-nodes, update_cumulative_edgelist()

Examples

Run this code
if (FALSE) {
el_cuml <- dedup_cumulative_edgelist(el_raw)
}

Run the code above in your browser using DataLab