In the previous handout we saw how to fit exponential random graph models (ergms) for simple undirected networks. As noted, these models are useful for multivariate null hypothesis testing using network data, answering questions of the form: Is this network statistic larger or smaller than I would expect by chance, after conditioning (e.g., “controling for”) these other network statistics?
The ergm modeling framework is pretty flexible, allowing you to test for the statistical significance of any network statistic you can imagine while holding constant a bunch of other ones.
Here we will see how to extend the ergm framework to other types of directed, two-mode, and temporal networks.
ERGMs in Directed Networks
The extension to the directed case is the most straightforward.
The key network statistic that we need to think about in the directed case is reciprocity or mutuality, namely, the fact that in the directed case, it is possible that I send a tie to you but you don’t send it back. In this advice network case this would happen if I seek advice from you, but you don’t seek advice from me.
In an ergm, we use the mutual term to condition on the number of dyads featuring arcs going on both directions (e.g., from \(i\) to \(j\)and from \(j\) to \(i\)).
Let’s see an example using Krackhardt’s High-Tech Managers:
Call:
ergm(formula = n1 ~ edges + mutual)
Monte Carlo Maximum Likelihood Results:
Estimate Std. Error MCMC % z value Pr(>|z|)
edges -1.5416 0.1553 0 -9.929 < 1e-04 ***
mutual 1.3320 0.3607 0 3.692 0.000222 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Null Deviance: 582.2 on 420 degrees of freedom
Residual Deviance: 451.6 on 418 degrees of freedom
AIC: 455.6 BIC: 463.7 (Smaller is better. MC Std. Err. = 0.3209)
m2 <-ergm(n2 ~ edges + mutual)summary(m2)
Call:
ergm(formula = n2 ~ edges + mutual)
Monte Carlo Maximum Likelihood Results:
Estimate Std. Error MCMC % z value Pr(>|z|)
edges -0.2752 0.1629 0 -1.690 0.0911 .
mutual 0.1693 0.2939 0 0.576 0.5647
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Null Deviance: 582.2 on 420 degrees of freedom
Residual Deviance: 578.2 on 418 degrees of freedom
AIC: 582.2 BIC: 590.2 (Smaller is better. MC Std. Err. = 0.05879)
Here we see strong evidence for mutuality effects in friendship nominations (\(\theta_m = 1.33, p < 0.01\)), consistent with the social meaning of the relation, but not in advice relations (\(\theta_m = 0.17, p = 0.57\)), suggesting that these ties are more hierarchical).
Next we may also want to fit models that condition on the different types of dependence between pairs of directed ties that are centered on the same node. There are three flavors of these types of dependencies:
Nodes that send a tie are more likely to send another tie. This is a rich get richer effect for outdegree.
Nodes that receive a tie are more likely to receive another tie. This is a rich get richer effect for indegree.
Nodes that send/receive a tie are more like to receive/send a tie. This fits the correlation between in and outdegree at the node level. If positive, nodes that send ties also receive ties.
The respective ergm terms for these three effects are ostar(2), istar(2) and twopath.
Let’s test for a twopath effect in the friendship and advice networks:
Call:
ergm(formula = n2 ~ edges + mutual + twopath)
Monte Carlo Maximum Likelihood Results:
Estimate Std. Error MCMC % z value Pr(>|z|)
edges 3.11004 0.51671 0 6.019 <1e-04 ***
mutual 0.48283 0.30122 0 1.603 0.109
twopath -0.20636 0.03315 0 -6.225 <1e-04 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Null Deviance: 582.2 on 420 degrees of freedom
Residual Deviance: 542.9 on 417 degrees of freedom
AIC: 548.9 BIC: 561 (Smaller is better. MC Std. Err. = 0.7573)
We can see that in the friendship network, there is no two path effect (\(p = 0.76\)); that is, people who send friendship nominations are not more or less likely to receive them.
However, in the advice network, we see a significant and negative two path effect (\(\theta_{2p} = -0.21\)); people who seek advice are less likely to be sought as advisors from others, which makes sense.
Now let’s look at rich get richer effects by indegree: Are people who are nominated as friends byy one person more likely to be nominated as friends by others? Are people who are sought after for advice by one person more likely to be sought after for advice by others?
Call:
ergm(formula = n2 ~ edges + mutual + twopath + istar(2))
Monte Carlo Maximum Likelihood Results:
Estimate Std. Error MCMC % z value Pr(>|z|)
edges 0.85773 0.78088 0 1.098 0.2720
mutual 0.77351 0.31932 0 2.422 0.0154 *
twopath -0.15003 0.03577 0 -4.194 <1e-04 ***
istar2 0.13288 0.03318 0 4.005 <1e-04 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Null Deviance: 582.2 on 420 degrees of freedom
Residual Deviance: 534.1 on 416 degrees of freedom
AIC: 542.1 BIC: 558.3 (Smaller is better. MC Std. Err. = 0.7616)
We can that friendship network displays not cumulative advantage by indegree, but that they advice network does (\(\theta_{is} = 0.13\)), consistent with the idea that the latter is more unequal and hierarchical. Note also that once we adjust for the two path and the rich get richer indegree effect, we can see a strong mutuality effect in advice relations (\(\theta_{m} = 0.77\)).
Now, let’s adjust for the tendency of people who send one tie, to send other ties:
We can now see that in contrast to the previous null results, there is outdegree dependency between nominations sent by the same node in the friendship network: People who nominate one person as a friend tend to nominate others (\(\theta_{os} = 0.27, p < 0.01\)).
In the advice network, we can see that all tendencies are operative, as the network displays all forms of degree dependence at the node level, along with mutuality.
We can also incorporate homophily based non attributes into our analysis of reciprocity. That is, we can test hypotheses of the form: Is mutuality weaker or stronger for dyads that match on a certain characteristic?
For instance, we may suspect that friendship ties among high-tech managers are influenced by formal organizational position, so that there is more mutuality within levels (e.g., mid-manager to mid-manager) than across levels (mid to lower-level).
Recall than in this network there are three managerial level but only one top manager, so we should compare the middle level to the rest
We can test this hypothesis as using the same argument in the mutual ergm term:
And indeed, we find that compared to lower level managers, tendencies toward mutuality in friendship choices are stronger among mid-level managers. Note that once we adjust for this attribute-specific mutuality effect, the two path effect in the advice network is no longer significant. We can also test hypotheses of the form: Are nodes with certain characteristics more likely to be involved in mutual dyads regardless of the characteristics of the node at the other end of the tie? That is, this tests for differential tendencies toward mutuality based on attribute.
We can do this using the by argument in the mutual term. This time using department as the relevant attribute:
The results show that, in the friendship network, nodes in Dept 2 tend to have more mutual ties compared to nodes in Dept 1 (the reference), in the advice network both nodes in Dept 2 and and Dept 4 tend to have more mutual ties, while nodes in Dept 3 are not statistically different from nodes in Dept 1.