Social network analysis (SNA) is the methodical analysis of social networks. Social network analysis views social relationships in terms of network theory, consisting of nodes (representing individual actors within the network) and ties (which represent relationships between the individuals, such as friendship, kinship, organizational position, sexual relationships, etc.)
Questions tagged [sna]
296 questions
0
votes
1 answer
Creating classes on vertices data frame from components$membership
I am looking to add a 'description' variable to the vertices data frame which describes the cluster in which a node is found. My network is family relationships so clusters could be a family of two adults and two children, single parent with three…

williamg15
- 77
- 7
0
votes
2 answers
R, error in finding degree, closeness and betweenness
Trying to apply the common measures of centrality to a simple data set of non-directed like this:
It gives error:
Error in closeness(net, gmode = "graph") : unused argument (gmode = "graph")
When I removed the argument (gmode = "graph), it…

Mark K
- 8,767
- 14
- 58
- 118
0
votes
1 answer
How to use List of List of Dataframes
I´m not sure if this is possible or even how to get a good resolution for the following R problem.
Data / Background / Structure:
I´ve collected a big dataset of project based cooperation data, which maps specific projects to the participating…

Mr.Morgan
- 31
- 1
- 6
0
votes
1 answer
Identifying and summarizing discrete groups of nodes in R
I am working on a networking problem related to family/household composition. I have multiple edge tables containing id1, id2 and a relationship code to state the type of relationship between the identity variables. These tables are large, upwards…

williamg15
- 77
- 7
0
votes
1 answer
Network Generator in networkx from existing nodes
Im trying to generate a social network in networkx. To do this I want to use the barabasi_albert_graph network generator. I want to be able to generate the nodes separately in pandas so I can give them specific attributes, but then have the…

Liam Mcconnachie
- 13
- 4
0
votes
1 answer
The issue with using images as vertices in igraph R
I'm trying to set images to vertices by their attribute (type), using this code:
library(igraph)
library(png)
gi <- graph.formula(child -- org -- person)
img1 <- readPNG("baby-boy.png")
img2 <- readPNG("knife.png")
img3 <-…

Hanna Kurovska
- 39
- 4
0
votes
0 answers
Create a networkx bipartite graph with a Stack Overflow dataset > 5m nodes, need advices and recommendations
I'm doing a project about data visualization and sna and I'm working with the Stack Overflow temporal network dataset (http://snap.stanford.edu/data/sx-stackoverflow.html). The dataset represents the interactions between users on Stack Overflow, ex.…

Sara
- 1
- 1
0
votes
1 answer
Assign same Group ID to ID with same values - Recursive sql query
The table contains PID and corresponding values. PIDs with same values should be assigned same group id. A, B, D are directly connected (value = ABC) and since C is connected with D (value = GHI), A,B,C & D are all part of the same group.
PID …

M s
- 1
- 1
0
votes
0 answers
cannot add attribute to bipartite network of class sna
I am trying to format data to run an ERGM model. However, I have problems combining the two data sets that I would like to use for the ergm model. First, my actual data set is a bipartite network with the first type of nodes (politicians) as rows…

S Front
- 333
- 1
- 8
0
votes
2 answers
R-Converting Incidence matrix(csv file) to edge list format
I am studying social network analysis and will be using Ucinet to draw network graphs. For this, I have to convert the csv file to an edge list format. Converting the adjacency matrix to the edge list was successful. However, it is difficult to…

C.H.
- 1
- 1
0
votes
1 answer
Creating a conditional that reads from multiple dataframes in R
I am trying to clean up data for social network analysis, and as a newcomer to coding, I'm having trouble writing a complex conditional.
First, we have dataframe bookinfo where the headers of interest are Date, Receiver, bookID:
>head(bookinfo)
…

c. lam
- 25
- 5
0
votes
1 answer
How to get all the shortest paths of the length of the diameter for iGraph object?
I want to get all the longest shortest paths for iGraph object. There is this function
get.diameter (graph, directed = TRUE, unconnected = TRUE)
But it returns only one path. So if there are many shortest paths of the length of the diameter, then…

Ali Zuhair
- 303
- 4
- 17
0
votes
2 answers
creating a edgelist from a dataframe
I am trying to get from this:
session location sequence weight INDIVIDUAL action
a1 texas 1 10 john Z1
a1 texas 2 5 peter Z2
a1 texas 3 3 ben Z1
a1 texas 4 …

Beavis
- 94
- 9
0
votes
0 answers
How to get the list returned by this function in a way that I can extract all elements from it?
This is a network matrix:
x <- matrix(c(0,0,0,0,0,
0,0,1,0,0,
1,0,0,1,0,
0,1,0,0,1,
0,1,0,0,0), nrow = 5, byrow = TRUE)
This function will return all possible subnetworks of a network in a…

Mitul Shah
- 1
- 3
0
votes
1 answer
Assigning several colors to nodes on the same network graph in R
I think this is really basic, but we can't seem to find an answer to this question. We are building a network analysis graph, and would like to color each node based on attributes. We are able to do two colors, but need to do more than that. We are…