sim.field.network.stats
Class DyadTriadStatistics
java.lang.Object
sim.field.network.stats.DyadTriadStatistics
public class DyadTriadStatistics
- extends java.lang.Object
Method Summary |
static int[] |
dyadCensus(Network network)
Computes thw dyad census (Wasserman and Faust, pages 512). |
static int |
getNumberDirectTriads(Network network,
java.lang.Object node1,
java.lang.Object node2)
Returns the number of direct triads
(number of parent nodes that point to both nodes sent as parameters). |
static int[] |
triadCensus(Network network)
Computes the triad census (Wasserman and Faust, pages 564-567). |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TRIAD_003
public static final int TRIAD_003
- See Also:
- Constant Field Values
TRIAD_012
public static final int TRIAD_012
- See Also:
- Constant Field Values
TRIAD_102
public static final int TRIAD_102
- See Also:
- Constant Field Values
TRIAD_021D
public static final int TRIAD_021D
- See Also:
- Constant Field Values
TRIAD_021U
public static final int TRIAD_021U
- See Also:
- Constant Field Values
TRIAD_021C
public static final int TRIAD_021C
- See Also:
- Constant Field Values
TRIAD_111D
public static final int TRIAD_111D
- See Also:
- Constant Field Values
TRIAD_111U
public static final int TRIAD_111U
- See Also:
- Constant Field Values
TRIAD_030T
public static final int TRIAD_030T
- See Also:
- Constant Field Values
TRIAD_030C
public static final int TRIAD_030C
- See Also:
- Constant Field Values
TRIAD_201
public static final int TRIAD_201
- See Also:
- Constant Field Values
TRIAD_120D
public static final int TRIAD_120D
- See Also:
- Constant Field Values
TRIAD_120U
public static final int TRIAD_120U
- See Also:
- Constant Field Values
TRIAD_120C
public static final int TRIAD_120C
- See Also:
- Constant Field Values
TRIAD_210
public static final int TRIAD_210
- See Also:
- Constant Field Values
TRIAD_300
public static final int TRIAD_300
- See Also:
- Constant Field Values
MAN_TRIAD_CLASSES
public static final java.lang.String[] MAN_TRIAD_CLASSES
DYAD_MUTUAL
public static final int DYAD_MUTUAL
- See Also:
- Constant Field Values
DYAD_ASYMMETRIC
public static final int DYAD_ASYMMETRIC
- See Also:
- Constant Field Values
DYAD_NULL
public static final int DYAD_NULL
- See Also:
- Constant Field Values
DYAD_CLASSES
public static final java.lang.String[] DYAD_CLASSES
DyadTriadStatistics
public DyadTriadStatistics()
triadCensus
public static int[] triadCensus(Network network)
- Computes the triad census (Wasserman and Faust, pages 564-567).
It assumes a single asymmetric relation where weights are irrelevant.
- Returns:
- 16-length int array
getNumberDirectTriads
public static int getNumberDirectTriads(Network network,
java.lang.Object node1,
java.lang.Object node2)
- Returns the number of direct triads
(number of parent nodes that point to both nodes sent as parameters).
dyadCensus
public static int[] dyadCensus(Network network)
- Computes thw dyad census (Wasserman and Faust, pages 512).
It assumes a single asymmetric relation where weights are irrelevant.
O(n^2) space and time.
I could do O(1) space and n x outdegree^2 time, but that's O(n^3) worst time
- Returns:
- 3-length int array