GreedyInit: GreedyInit

Description Usage Arguments Value See Also Examples

View source: R/greedy_init.R

Description

Initialises the allocation variables using k-means.

Usage

1
GreedyInit(adj_cube, Kup, list_of_inactive_nodes = NULL)

Arguments

adj_cube

A binary array of size NxNxT representing the dynamic network. The generic entry in position [i,j,t] is equal to 1 if i interacts with j during the t-th time frame, or to 0 otherwise. Only undirected networks with no self-edges are supported, so each slice of the array must be a symmetric matrix with null elements on the diagonal.

Kup

Number of groups: must be a positive integer between 1 and N.

list_of_inactive_nodes

A matrix whose rows identify all of the inactive nodes in the network. The first element of each row denotes the time frame t, while the second element the node label i: the inactive nodes are identified by all such pairs (t,i).

Value

The function returns a TxN allocation matrix, with zeros corresponding to inactive nodes.

See Also

GreedyICL, GreedyMerge, CollapseLabels.

Examples

1
### A complete example is provided in the documentation of GreedyMerge.

GreedySBTM documentation built on May 2, 2019, 12:40 a.m.