This document describes a project analyzing ego networks on Facebook data. The project aims to help compare ego networks and suggest friends. It uses algorithms like triangle enumeration and fast ego network construction. The team implemented these algorithms in Python using NetworkX and other tools. They demonstrated the analysis and want to detect communities and important individuals next. The conclusion is that ego networks are clusterable and could help with tasks like friend suggestion.
1. Project Name: Ego-Net Facebook data Analysis
Group Member:
Student of Computer Science and Engineering Department of
Daffodil International University, Dhaka
Samsil Arefin 161-15-7197
Ashik-E-Rabbani 161-15-7093
Arman Fazlur Rahman 161-15-6991
Mizanur Rhman 161-15-7126
Md. Hasnain Habib Rakin 161-15-7379
Submitted To:
Ahmed Al Marouf
Lecturer (Computer Science) at Daffodil International University
Course Information:
Course code: CSE222
Course title: Algorithms Lab
Submission Date: 13-08-17
2. Ego-Net Facebook Data Analysis
Introduction
Ego-Network analysis is critically important for largescale social network analysis. Ego-
Networks are a kind of special social networks. Unlike common social networks, an ego-network
has a particular central node designated as an ego. Other nodes in the network, direct or indirect
neighbors of the ego, are called alters. An ego-network shows the relations among the ego and its
neighborhood. Important insights can be obtained by comparing ego-networks of different entities
when exploring and analyzing social networks.1,2 In a social network, the closeness of two people
can be represented by the similarity of their ego-networks. For example, in an Academic
Collaboration Network, Different Collaboration Patterns can be revealed by comparing two
authors’ ego-networks.
Although people have gradually realized the importance of ego-centric analysis, it is still a
very challenging task to visually tell the difference among multiple ego-networks in a huge and
dense network (i.e. large graph).4 This work attempts to address the challenge by introducing ego-
Comp, a technique which focuses on the analysis of node difference of two ego networks. The
technique can be easily integrated into large-scale network analysis to facilitate visual comparison
and exploration of ego-networks.
Objectives
To evaluate the ability to facilitate comparing ego-networks, we conducted a usability
study. The goal of this study is to find out whether the ego is helpful for users to explore and
compare the social networks like Facebook, Twitter and other Social Network.
Motivation
The study of a practical application of ego-networks clustering to the important task of friend
suggestion motivate us more. As a driver of social engagement, friend suggestion is a fundamental
tool for online social networks. Designing a high quality system is very challenging and the state
of the art friend suggestions tools are based on a multitude of features combined by efficient
Machine Learning algorithms.
3. Features
The program allows to create questionnaires, collect data and provide comprehensive measures
and arrays of data that can be used for subsequent analysis by other software. Its main benefits are
the generation of questionnaires for relational data, the calculation of relevant General
measurements for the analysis of social networks and production graphs.
Diagram
If the ego-net is considered as social net like Facebook then the nodes are: Choices and Edges
are choice between them which can build up a friendship with much similarity also can suggest
as friend.
Implementation Requirements
1. Knowledge of Graph theory.
2. EgoCentric Network Knowledge
3. Python Interpreter.
4. Also need to know the basic logic of coding.
Software Requirements
1. Pycharm or Any other IDE
2. NetworkX module
3. Metasploit.lib module
4. Windows OS / MacOS / Linux.
4. Implementation Requirements
1. Proper knowledge about Ego-Networking
2. Graph Theory
3. Snap Data of Facebook
4. Object Oriented Programming
5. Knowledge about higher level Programming language like Python, Go
Software Requirements
1. Operating System : Windows/Linux
2. Programming Language : Python
3. Tools : Networkx, Matplotlib
Algorithms
We mainly used the modules which are based on algorithms: Schank’s algorithm for
Enumerating Triangles, Fast Ego-Network construction algorithms, Fast Parallel Ego-Network
construction algorithms.
1 .Schank’s algorithm for Enumerating Triangles
Input: G(V,E)
Output: All triangle of G
while V 6= ∅ do u → node of minimal degree.
for ∀v,z ∈ N(u) do
if (v, z) ∈ E then
Output triangle u,v,z
end if
end for
Delete node u and its adjacent edges.
end while
2. Fast Ego-Network construction algorithms
Input: G(V,E)
Output: All ego-nets of nodes of G.
while V 6= ∅ do u → node of minimal degree.
for ∀v,z ∈ N(u)
do
if (v,z) ∈ E then
Add (u,v) to Sz
}It shows that such
algorithm requires
O(m)^3/2 time.
5. Add (v,z) to Su
Add (u,z) to Sv
end if
end for
Delete node u and its adjacent edges.
end while
3 .Fast Parallel Ego-Network construction algorithms
Map: Input: edge (u,v)
{Let h(·) be a universal hash function into [0,ρ]}
i ←dh(u)e
j ←dh(v)e if i == j then
for z ∈{1,2,...,ρ}∧z 6= i
do
for w ∈{1,2,...,ρ}∧w 6= i,z
do
Output (sorted(i,z,w),(u,v))
end for
end for
else
for z ∈{1,2,...,ρ}∧z 6= i,j
do
Output (sorted(i,j,z),(u,v))
end for
end if
Reduce: Run Algorithm 2 on the input graph
7. Future Prospective
Our Aim is to demonstrate the Community detection and Parallel Betweenness in the Outputted
graph. And also Use the Graph result is our real life. Like with the community detection we can
categorized any places based on their wants and then it can be easier to the Govt. and also the
helper to help the affected or needy areas. How do we determine who is the most "important"
individual in the network. Well, that depends on the definition of "important". One way to define
"importance" is the individual's betweenness centrality. The betweenness centrality is a measure
of how many shortest paths pass through a particular vertex. The more shortest paths that pass
through the vertex, the more central the vertex is to the network. Hence, we can only provide what
data is permitted by the Facebook host, via APIs. There are a few fields for individuals that are
currently available from Facebook that is not yet part of our implementation. For example, Users’
Hometown-location, Gender, and their location (City and State) are available; this attribute data
will be made part of our implementation in the future, assuming that Facebook keeps these data
available to developers via the APIs.
Conclusion
In this paper we focus on analyzing the structural properties of ego-networks. Our findings are
quite interesting, ego-networks are easily cluster able and the user defined circles are somehow
similar to the cluster retrieved by classic clustering algorithms. Toward this end we also developed
an efficient technique to cluster all the ego-networks in a graph in parallel efficiently.
We believe that many future directions of work might stem from our preliminary results. For
instance, ego-networks mining and the study of ego-nets structure in bipartite graphs might be
worth to be explored. Also, ego-net mining could be potentially used to detect spam requests to
join circles. Moreover, better performances in friend suggestion could be obtained by combining
the result of the application of different clustering methods.
8. References
Carley, Kathleen. (1991). A Theory of Group Stability. American sociological Review, 56, 331-
354.
Wikipedia (2017). Facebook. Retrieved on 25 July, 2017, http://en.wikipedia.org/wiki/Facebook.
Tsvetovat, Max & Reminga, Jeffrey & Carley, Kathleen. (2003). DyNetML: Interchange Format
for Rich Social Network Data. NAACSOS Conference 2003, Day 2, Electronic Publication,
Pittsburgh, PA.