getFactions {mFLICA} | R Documentation |
getFactions function
Description
getFactions is a support function for inferring faction leaders and their members as well as a faction size ratio of each faction. Leaders are nodes that have zero outgoing degree. Members of leader A's faction are nodes that have some directed path to A in a following network.
Usage
getFactions(adjMat)
Arguments
adjMat |
is an adjacency matrix of a following network. |
Value
This function returns a list of leader IDs, a list of faction members, and network densities of factions.
leaders |
is a list of faction leader IDs |
factionMembers |
is a list of members of factions where |
factionSizeRatio |
is a vector of faction size ratio of each faction.
|
Examples
# Given an example of adjacency matrix
A<-matrix(FALSE,5,5)
A[2,1]<-TRUE
A[c(3,4),2]<-TRUE
A[5,3]<-TRUE
# Get faction leaders and their members as well as a network density of each faction.
out<-getFactions(adjMat=A)