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
In-Degree Bonacich Power Centrality in R?
Thank you for your time in advance. I am attempting to identify a method to calculate in-degree Bonacich Power Centrality in R. I'm a long-time UCINET user attempting to make the switch. In UCINET, this is done selecting Beta Centrality (Bonacich…

Jonathan D.
- 17
- 5
0
votes
1 answer
Transform event list dataframe in adjacency dataframe
I have a df in which every columns represent an event and in cells there are the individuals, like this:
df=data.frame(topic1=c("a", "b","c", "d"), topic2=c("e","f", "g", "a"), topic3=c("b","c","g","h"))
I need to transform it in adjacency df, like…

ErreEmme
- 17
- 4
0
votes
1 answer
Counting edges in a graph by the attribute of nodes they connect
Sorry for the vague question, I'm having difficulties in specifying exactly what I need. I hope the example will make it clearer.
I have a network with various node attributes (like country affiliation, etc.). I am interested in how many of the…

Zlo
- 1,150
- 2
- 18
- 38
0
votes
1 answer
How can I convert rows with start and end time columns into time-series format in R?
I am working with radio communications data that has the following data structure (P1-P5 are recipient columns):
Index Onset Terminus Duration Sender Net P1 P2 P3 P4 P5 …

Glenn Lematta
- 5
- 3
0
votes
1 answer
Attempting to recreate a network, how to assign edge weight to specific edges?
So I have been tasked with recreating a specific network as seen here:
While I have been able to figure out how to play around with the nodes, I am unsure how to assign each edge to a width. I am assuming it should be done similarly to node…

Johnny Thomas
- 623
- 5
- 13
0
votes
1 answer
how to find centrality of nodes within clusters using i- graph and python
I'm working on network analysis and I'm new to python. I want to find out the centrality of every node within a cluster using i graph and python pandas.
I have tried the following:
Creating a graph:
tuples = [tuple(x) for x in…

SAM
- 9
- 1
0
votes
2 answers
Controlling dynamic vertex attributes using networkDynamic and/or ndtv
I am looking at how government agencies change over time. The plan is to use the ndtv package to visualise changes. I have an nodelist that lists vertex ids, agency name, node onset and node terminus:
nodelist <-…

aterhorst
- 625
- 4
- 14
0
votes
1 answer
What are Non-overlapping community detection algorithms that I can use using Python iGraph?
What are Non-overlapping community detection algorithms that I can use using Python iGraph?
I tried to search a lot on this but I cound't find answer, please guide me here...

HQuser
- 640
- 10
- 26
0
votes
1 answer
How to Hide Output From sna::components?
I try running
library(sna)
g <- rgraph(100, tprob=0.1)
cmp <- invisible(components(g))
And it still prints output. I want no output.
Node 1, Reach 100, Total 100
Node 2, Reach 100, Total 200
Node 3, Reach 100, Total 300
Node 4, Reach 100, Total…

Wassadamo
- 1,176
- 12
- 32
0
votes
1 answer
Formatting onset terminus data for dynamic network visualisation
I am looking at how government agencies change over time. The plan is to use the ndtv package to visualise changes. However, I am running into problems and have no idea what I am doing wrong! I suspect my data is not formatted correctly.
I have an…

aterhorst
- 625
- 4
- 14
0
votes
1 answer
How to get an average between two columns to condense the rows by using SQL in Social Network Analysis (SNA)
I have three columns: Sender, Receiver, # of Text Messages.
I need to condense the rows by getting the average of two columns.
So let's say Carol sends Jack 8 text messages, and Jack sends Carol 4 text messages, the result would be 6 messages…

user10631408
- 1
- 2
0
votes
1 answer
How can I choose specific parts of a string?
I need to select Twitter handle names from retweets and create a list of usernames. I wonder how I can select text within a string that start with "@". Here's an example for a retweet.
@MyBrianLeyh @IngrahamAngle @TombStoneBub @MeticulousPaul…

Chamil Rathnayake
- 119
- 1
- 10
0
votes
1 answer
How to get triad census in undirected graph using networkx in python
I have an undirected networkx graph as follows and I want to print triad census of the graph. However, nx.triadic_census(G) does not support undirected graphs.
import networkx as nx
G = nx.Graph()
G.add_edges_from(
[('A', 'B'), ('A', 'C'), ('D',…

EmJ
- 4,398
- 9
- 44
- 105
0
votes
1 answer
How to get the details of triads in r/python?
I am currently using igraph to get the traid census of a given directed graph usingtriad_census(g). This returns the count of triads in each of the 16 classes.
e.g., 16 3 0 10 1 0 0 0 0 0 0 0 0 0 0 0
However, I would like to know more…

EmJ
- 4,398
- 9
- 44
- 105
0
votes
0 answers
Extract Tweets of a particular user
I am trying to get the tweets of a particular user on a specified period.
#Extract tweets from Donald Trump Timeline
dt_tweets = userTimeline("realDonaldTrump", n = 320, sinceID = "2016-11-09",
maxID = "2019-01-28", includeRts = FALSE)
I got a…

Anjan Karpak
- 15
- 6