tnetwork.DynCommunitiesSN.add_affiliation

DynCommunitiesSN.add_affiliation(nodes, cIDs, times)[source]

Affiliate node(s) to community(ies) at time(s)

Add belonging for the provided node(s) to the provided communitie(s) at the provided time(s). (all nodes, at all times, in all communities) If communities do not exist, they are created.

Parameters:
  • nodes – accept set/list of nodes or single node
  • times – accept list of times or single time
  • cIDs – accept lists of coms or single com
Returns: