homework
POLI 100F Lecture 2: Social Network Mechanics
Gregoire Phillips
University of California, San Diego
October 12, 2020
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 1 / 38
Overview
1 Announcements
2 Social Network Structures
3 Centrality
4 Clustering
5 Wrap-Up
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 2 / 38
A few brief reminders
Try to get required readings done before watching lecture
Readings with triple asterisks are recommended, but not required, readings
We may engage with both in the lecture, but will only expect you to be familiar with what is required
No participation quiz this week (because we still have people adding the course)
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 3 / 38
Review: What is a social network?
Social networks describe connections built on social interactions, relationships, associations, and influence
The simplest network is a dyad, or pair of individuals
Sometimes, these dyads agglomerate to form large, interconnected web structures
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 4 / 38
Review: What is a social network?
Social networks describe connections built on social interactions, relationships, associations, and influence The simplest network is a dyad, or pair of individuals
Sometimes, these dyads agglomerate to form large, interconnected web structures
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 4 / 38
Review: What is a social network?
Social networks describe connections built on social interactions, relationships, associations, and influence The simplest network is a dyad, or pair of individuals
Sometimes, these dyads agglomerate to form large, interconnected web structures
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 4 / 38
Social network mechanics
A network is defined by a set of “nodes” and all “links” that connect pairs of them.
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 5 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 6 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 7 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 8 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 9 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 10 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 11 / 38
Social network mechanics
This one isn’t useful if we want to learn something from the visual Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 12 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 13 / 38
Social network mechanics
Links can be undirected or directed Directed links can be unidirectional or bidirectional
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 14 / 38
Social network mechanics
We can think of networks mathematically as lists of edges linking nodes
We call this an edgelist
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 15 / 38
Social network mechanics
Finally, we can think of networks as matrices (in math, not science fiction)
We can represent them with something called an “adjacency matrix”
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 16 / 38
Social network mechanics
Finally, we can think of networks as matrices (in math, not science fiction)
We can represent them with something called an “adjacency matrix”
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 17 / 38
Social network mechanics
Finally, we can think of networks as matrices (in math, not science fiction)
We can represent them with something called an “adjacency matrix”
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 18 / 38
Social network mechanics
How do we think about network size?
One way we talk about this is network diameter
To understand this, let’s talk about walks and paths
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 19 / 38
Social network mechanics
How do we think about network size?
One way we talk about this is network diameter
To understand this, let’s talk about walks and paths
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 19 / 38
Social network mechanics
How do we think about network size?
One way we talk about this is network diameter
To understand this, let’s talk about walks and paths
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 19 / 38
Social network mechanics
Walk: sequence of nodes connected by links. We can “walk” from node to node along links
Path: sequence of nodes connected by links that does not repeat any nodes (except maybe the first and last)
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 20 / 38
Social network mechanics
Walk: sequence of nodes connected by links. We can “walk” from node to node along links
Path: sequence of nodes connected by links that does not repeat any nodes (except maybe the first and last)
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 20 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 21 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 22 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 23 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 24 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 25 / 38
Social network mechanics
Number of links traversed in this walk: 6
But how can we use walks to measure networks?
Answer: measure the shortest walk, or the network diameter
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 26 / 38
Social network mechanics
Number of links traversed in this walk: 6
But how can we use walks to measure networks?
Answer: measure the shortest walk, or the network diameter
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 26 / 38
Social network mechanics
Number of links traversed in this walk: 6
But how can we use walks to measure networks?
Answer: measure the shortest walk, or the network diameter
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 26 / 38
Social network mechanics
Number of links traversed in this walk: 2 This network’s diameter is not 2, though. We need the longest shortest path What is it?
It’s 3. Longest shortest path is from 1-5.
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 27 / 38
Social network mechanics
Number of links traversed in this walk: 2 This network’s diameter is not 2, though. We need the longest shortest path What is it? It’s 3. Longest shortest path is from 1-5.
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 27 / 38
Social network mechanics
Network Diameter
Length of the longest shortest path in the network
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 28 / 38
Social network mechanics
Now we have 2 components to our network
What is this network’s diameter?
Answer: 3 – longest shortest path
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 29 / 38
Social network mechanics
Now we have 2 components to our network
What is this network’s diameter?
Answer: 3 – longest shortest path
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 29 / 38
Social network mechanics
Now we have 2 components to our network
What is this network’s diameter?
Answer: 3 – longest shortest path
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 29 / 38
Social network mechanics
We can now describe network nodes, links/ties, and size.
But how do we measure the connectedness of individuals within networks?
Another way of thinking about this: how do we measure a node’s importance within a network?
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 30 / 38
Social network mechanics
We determine a node’s importance within a network by measuring it’s centrality. We can measure this several ways:
Total number of direct connections (“degree” centrality)
How close a node is to all other nodes (“closeness” centrality )
How many “shortest paths” cross through a node? (“betweenness centrality”)
How close is a node to other important nodes (“eigenvector centrality”)
Let’s break down two of these in detail: degree and closeness centrality
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 31 / 38
Social network mechanics
To calculate degree centrality, count the number links coming directly from the node in question
Then divide this number by the number of nodes, n, minus 1
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 32 / 38
Social network mechanics
Closeness centrality is a bit more complex
To calculate this, count the number of nodes and subtract 1 again
Then take the sum of the number of links separating the node in question from each other node in the network
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 33 / 38
Social network mechanics
Closeness centrality is a bit more complex
To calculate this, count the number of nodes and subtract 1 again
Then take the sum of the number of links separating the node in question from each other node in the network
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 33 / 38
Social network mechanics
Closeness centrality is a bit more complex
To calculate this, count the number of nodes and subtract 1 again
Then take the sum of the number of links separating the node in question from each other node in the network
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 33 / 38
Social network mechanics
So now we have an idea of what centrality is
But centrality doesn’t really tell us about how “dense” a network is
How many of a given node’s friends are also friends with each other?
This is called clustering
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 34 / 38
Social network mechanics
So now we have an idea of what centrality is
But centrality doesn’t really tell us about how “dense” a network is
How many of a given node’s friends are also friends with each other?
This is called clustering
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 34 / 38
Social network mechanics
So now we have an idea of what centrality is
But centrality doesn’t really tell us about how “dense” a network is
How many of a given node’s friends are also friends with each other?
This is called clustering
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 34 / 38
Social network mechanics
So now we have an idea of what centrality is
But centrality doesn’t really tell us about how “dense” a network is
How many of a given node’s friends are also friends with each other?
This is called clustering
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 34 / 38
Social network mechanics
This is what clustering looks like, in math.
(Don’t worry – we aren’t going to do math)
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 35 / 38
Social network mechanics
This is what clustering looks like, in math.
(Don’t worry – we aren’t going to do math)
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 35 / 38
Social network mechanics
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 36 / 38
Social network mechanics
We now have an understanding of
How networks are structured
How to measure distance in a network
How to measure the importance of nodes within a network through centrality
How to measure “closeness” through clustering
We will return to other concepts of centrality and clustering as we encounter them, but we now have enough basic knowledge and language to describe networks and their impact on behavior
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 37 / 38
Social network mechanics
We now have an understanding of
How networks are structured
How to measure distance in a network
How to measure the importance of nodes within a network through centrality
How to measure “closeness” through clustering
We will return to other concepts of centrality and clustering as we encounter them, but we now have enough basic knowledge and language to describe networks and their impact on behavior
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 37 / 38
Social network mechanics
We now have an understanding of
How networks are structured
How to measure distance in a network
How to measure the importance of nodes within a network through centrality
How to measure “closeness” through clustering
We will return to other concepts of centrality and clustering as we encounter them, but we now have enough basic knowledge and language to describe networks and their impact on behavior
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 37 / 38
Social network mechanics
We now have an understanding of
How networks are structured
How to measure distance in a network
How to measure the importance of nodes within a network through centrality
How to measure “closeness” through clustering
We will return to other concepts of centrality and clustering as we encounter them, but we now have enough basic knowledge and language to describe networks and their impact on behavior
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 37 / 38
Social network mechanics
We now have an understanding of
How networks are structured
How to measure distance in a network
How to measure the importance of nodes within a network through centrality
How to measure “closeness” through clustering
We will return to other concepts of centrality and clustering as we encounter them, but we now have enough basic knowledge and language to describe networks and their impact on behavior
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 37 / 38
Social network mechanics
Over the next two weeks, we’re going to dive into:
Social networks and health (Week 3)
Social networks and our social lives (Week 4)
See you then!
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 38 / 38
Social network mechanics
Over the next two weeks, we’re going to dive into:
Social networks and health (Week 3)
Social networks and our social lives (Week 4)
See you then!
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 38 / 38
Social network mechanics
Over the next two weeks, we’re going to dive into:
Social networks and health (Week 3)
Social networks and our social lives (Week 4)
See you then!
Gregoire Phillips (UCSD) Social Data Analysis October 12, 2020 38 / 38
- Announcements
- Social Network Structures
- Centrality
- Clustering
- Wrap-Up