In this lab, you’ll be building, estimating, and interpreting actor-based longitudinal network models using RSiena.1 Tom Snijders has led the development of the Siena framework, with RSiena supplanting a specialized Windows program in 2011. You can learn more about RSiena, research using the framework, and more here. RSiena is used to model actor-based longitudinal network models in order to examine the effects of network ties over time on a certain behavior, or the effect of a certain behavior on tie formation over time. SIENA stands for Simulation Investigation for Empirical Network Analysis.
You will be using an excerpt of data from the Teenage Friends and Lifestyle Study.2 You can learn more about this data set, created by Prof. Snijders, here. The data set includes 3 network files containing friendship relationships between 50 teenage girls recorded at 3 consecutive points in time.
s50-network1.dat
s50-network2.dat
s50-network23.dat
The data also includes information about the smoking behavior of the 50 female students (s50-smoke.dat). The smoking variable has three levels: 1 (does not smoke), 2 (smokes occasionally) and 3 (smokes regularly).
The core analysis conducted in this lab consists of taking a set of intuitive or plain language hypotheses about our data set and converting them into hypotheses in network terminology. Once we have our hypotheses, we will operationalize them into parameters in our model. Finally, we will interpret these results by testing our hypotheses.
First, we will create testable hypotheses based on intuitions about habit and friendship formation.
Formulate hypotheses using network terminology discussed throughout the course based on the following friendship relations.3 If you get stuck, it may be helpful to look at the terms included in the model below for hints on how to translate plain-language intuitions into network terminology. The first one is done for you:
Hypothesis 1: Ties between students are not random.
Relational Hypotheses:
Hypothesis 2: Ties are reciprocal.
Hypothesis 3: Network closure will happen: many triangles.
Hypothesis 4: Smokers will become more and more isolated through time from nonsmokers (t1 to t3)
Hypothesis 5: Smokers will not form ties with non-smokers (two different clusters at t3)
Hypothesis 6: Smokers will form ties with other smokers (at t3)
Smoking Behavior Hypotheses:
Hypothesis 7: Smokers will be more likely to smoke more (compared to t3)
Hypothesis 8: At t1, if a non-smoker forms a tie with a smoker, the non-smoker will be more likely to smoke at t3. The reverse will not happen.
To better intuitively understand our network, let’s examine three network visualizations showing the friendship network over time and the smoking behavior of the nodes.
Let’s visualize our network at the three time periods under discussion. Node size increases with smoking behavior. Green nodes represent no smoking, yellow nodes represent light smoking, and red nodes represent heavy smoking. Think about the macro-level features of each network.
Which two nodes represent isolates in the network at all three time periods?
V20 and V13 represent isolates in the network at all three time periods.
Describe the change in the network over time. Think about the formation of clusters and the incidence of smoking behavior.
Network become polarized into different clusters in t3 compared to t1.
Using the three visualizations, evaluate hypothesis five.
Hypothesis 5 is supported. Since I suggested that smokers will be less likely to form ties with non-smokers, I observe 4 big clusters in the network.
To build a SIENA model, we need to create dependent variables, explanatory variables, a combination of both types of variables, and our model specification.
First, we create a SIENA data object including the longitudinal friendship network and the smoking behavioral variable. The results of creating that model, smokeBehXfriendship:
## Dependent variables: friendship, smokingbeh
## Number of observations: 3
##
## Nodeset Actors
## Number of nodes 50
##
## Dependent variable friendship
## Type oneMode
## Observations 3
## Nodeset Actors
## Densities 0.046 0.047 0.05
##
## Dependent variable smokingbeh
## Type behavior
## Observations 3
## Nodeset Actors
## Range 1 - 3
Using our hypotheses above, we will construct a list of parameters to test using our Siena model. A table of those parameters follows:
## name effectName include fix test
## 1 friendship constant friendship rate (period 1) TRUE FALSE FALSE
## 2 friendship constant friendship rate (period 2) TRUE FALSE FALSE
## 3 friendship outdegree (density) TRUE FALSE FALSE
## 4 friendship reciprocity TRUE FALSE FALSE
## 5 friendship smokingbeh alter TRUE FALSE FALSE
## 6 friendship smokingbeh ego TRUE FALSE FALSE
## 7 friendship same smokingbeh TRUE FALSE FALSE
## 8 smokingbeh rate smokingbeh (period 1) TRUE FALSE FALSE
## 9 smokingbeh rate smokingbeh (period 2) TRUE FALSE FALSE
## 10 smokingbeh smokingbeh linear shape TRUE FALSE FALSE
## 11 smokingbeh smokingbeh quadratic shape TRUE FALSE FALSE
## 12 smokingbeh smokingbeh total similarity TRUE FALSE FALSE
## initialValue parm
## 1 4.69604 0
## 2 4.32885 0
## 3 -1.46770 0
## 4 0.00000 0
## 5 0.00000 0
## 6 0.00000 0
## 7 0.00000 0
## 8 0.81720 0
## 9 0.43579 0
## 10 -0.22314 0
## 11 0.00000 0
## 12 0.00000 0
Next, we will create our model. You can learn about the function that creates Siena models by typing ?sienaModelCreate into your R console.
## Estimates, standard errors and convergence t-ratios
##
## Estimate Standard Convergence
## Error t-ratio
## Network Dynamics
## 1. rate constant friendship rate (period 1) 5.7098 ( 0.9549 ) -0.0401
## 2. rate constant friendship rate (period 2) 4.4677 ( 0.7266 ) -0.0809
## 3. eval outdegree (density) -2.7766 ( 0.2543 ) -0.0086
## 4. eval reciprocity 2.7716 ( 0.1917 ) -0.0214
## 5. eval smokingbeh alter 0.1155 ( 0.1508 ) -0.0008
## 6. eval smokingbeh ego 0.1220 ( 0.1654 ) 0.0089
## 7. eval same smokingbeh 0.7040 ( 0.3628 ) -0.0067
##
## Behavior Dynamics
## 8. rate rate smokingbeh (period 1) 3.1717 ( 1.2618 ) 0.0485
## 9. rate rate smokingbeh (period 2) 3.0621 ( 1.3119 ) -0.0890
## 10. eval smokingbeh linear shape -1.3958 ( 0.4039 ) -0.0153
## 11. eval smokingbeh quadratic shape 1.9457 ( 0.3829 ) -0.0079
## 12. eval smokingbeh total similarity 1.0786 ( 0.5275 ) -0.0149
##
## Overall maximum convergence ratio: 0.1565
##
##
## Total of 3126 iteration steps.
We need to check the convergence ratios in the final column to evaluate the reliability of our simulation. Individual t-ratios should be less than the absolute value of .1. The overall maximum convergence ratio should be less than .25.
Has your model converged sufficiently? If not, note which terms have not converged, rerun your model using the previous Siena model values as your starting point, and re-evaluate. Repeat this process until the overall maximum convergence ratio and the convergence t-ratio for each term are within acceptable levels.4 If your model has not converged, uncomment prevAns = ans1 in the code block titled Model Creation and rerun that block of code and print results. This will use the previous values generated by the previous model creation as the starting point in the estimation and proceed through the model construction process again. See pp. 58—59 of the RSiena manual for more information.
Yes, it has converged. The overall maximum convergence ratio is 0.15 which is less than the 0.25 cutoff point. Individual convergence ratio is also smaller than the 0.1 cutoff point.
The Estimate column, also reported as the theta vector within an RSiena object’s effects vector, represents the chance of an actor forming a tie within the network based on interactions within and between networks or in relation to the presence or absence of a behavior. The Standard Error column provides information about the amount of variation among actors within the network on the given parameter.
The following table presents the Estimate (theta) score from the preceding table, divided by Standard Error. Recall that when carrying out a t-test, a parameter is significant at the .05 level when the absolute value of the t-score is greater than 2.
| sigvalues | |
|---|---|
| constant friendship rate (period 1) | 5.98 |
| constant friendship rate (period 2) | 6.15 |
| outdegree (density) | -10.92 |
| reciprocity | 14.46 |
| smokingbeh alter | 0.77 |
| smokingbeh ego | 0.74 |
| same smokingbeh | 1.94 |
| rate smokingbeh (period 1) | 2.51 |
| rate smokingbeh (period 2) | 2.33 |
| smokingbeh linear shape | -3.46 |
| smokingbeh quadratic shape | 5.08 |
| smokingbeh total similarity | 2.04 |
For each of your hypotheses, indicate which parameter operationalizes your hypothesis. Using the tables created above, evaluate that hypothesis, and report whether your results were significant.5 If you’re having difficulty matching up parameters with your hypotheses, take a look at pp. 41-49, § 6.2, in the RSiena Manual.
Hypothesis 1: Given by constant rate at T1 and T2. This shows the rate of change in the three time points. This is supported for the t-scores are both more than 2.
Hypothesis 2: Given by reciprocity. This is supported for the t-score is 15.02.
Hypothesis 3: This should be given by transitivity but I can’t seem to find it in the parameters.
Hypothesis 4: This is given by smoking behavior ego, which is interpreted as, a smoker will name less friends than non-smokers. This hypothesis is not supported because the significance level is not good.
Hypothesis 5: Smokers are less attractive meaning they should have less alter. However, this is not supported given that the t-score is very small.
Hypothesis 6: Same smoking behavior should be the measure that operationalize this hypothesis however, it is not supported.
Hypothesis 7: This is not supported because the rate of smoking at t2 is less than the significance level, although the direction of the estimate is correct (that the older the more they will smoke).
Hypothesis 8: This is supported by outdegree effect.
After knitting your file to RPubs, copy the URL and paste it into the comment field of the Lab 2 Assignment on Canvas. Save this .Rmd file and submit it in the file portion of your Canvas assignment. Make sure to review your file and its formatting. Run spell check (built into RStudio) and proofread your answers before submitting. If you can’t publish to RPubs, save your HTML file as a PDF and submit that instead.6 There are many different ways to do this with different browsers. Google it.