Visualize you favorite Facebook Pages

How this idea came?

This feature is pretty interesting for me, and I liked connecting the dots. The story started when I saw a tweet from Avkash Chauhan wherein he mentioned the use of an open source tool Gephi for Data Visualization. He posted some videos related to how he was using Gephi to visualize the data at
It was pretty interesting and felt inline to what NetMe aims to achieve. We saw a potential to give more insights to user discussion and post related to the track keyword using a comprehensive analytics like Gephi. Gephi is an open source tool and was quick to learn and explore.


The dots were discrete. The approach that we thought was

1.       We will fetch all the tweets and FB posts from the corresponding social media platforms and then convert them into GEXF (Graph Exchange XML format) or GDF format which can be read by Gephi

2.       We will rank them by degree and assign colors according to their rank clearly differentiating which post are popular and which are not

3.       We will apply a clustering algorithm on the fetched GEXF or GDF. For our use we implemented Fruchterman Reingold algorithm as the aperture between the nodes or distance was optimal and helped us to avoid any kind of incorrigible/meaningless text.

4.       We will convert this preview to Web template and publish the same in NetMe


1.       Download Gephi 0.8.2 beta

2.       Download the Sigma.JS Template addon for Gephi which will help us to convert the data visualization in web template


 The dots were clear. Now it was the time to connect them. I faced few challenges doing this which I will mention as the blog goes.

1.       Fetch the GEXF or GDF format xml. GEXF or GDF is simply an xml file with some parameters which helps it to get exchanged into a Graph. You will find many APIs for this which are easy to use. Our aim was to fetch the Facebook posts related to liked pages. For this we have used the Facebook Netvizz API. This is an Oauth supported API which will need your authentication token, after authorizing the app you will be able to see all your pages and groups. Then it allows you to fetch post by page admin or post by page admin and other users.
2.         Once fetched, Open Gephi Tool and import this GDF data

3.       Once the data is imported Click on the Color tab in the top left menu bar and then select Degree as a category. Click on Apply
4.       Click on Size/Weight icon by the side of color bar and again click on degree apply the sizes and click Apply
Here I am mentioning the maximum size to be 50.5. This denotes that the 1st ranked post or the most popular post will have a weight of 50.5 and size 1 then as per weight the size and weight will decrease. 
5.       Choose Fruchterman Reingold algorithm from the Layout section and click Run
To see the text of the corresponding nodes you can click on “T” literal in the bottom menu bar. After doing this go to Preview Section by clicking on the button in the top menu bar.
6.       Click on File->Export-> Click on Sigma.JS template
After filling some details this addon will help you with a website template which will have 2 json files
a.       Config.JSON which will have the report related details
b.      Data.Json which will have the raw data which is required to build the graph.
7.       Clicking on any nodes will give more information about that node and also the users who have participated in that discussion. More insights can be seen such as how many discussion the user has participated, popular posts, popular user etc.
We are tracking 5 Facebook pages corresponding to Azure, Hadoop, Cloud, Microsoft and Windows8. Details at


Popular posts from this blog

Firebase authentication with Ionic creator

Big Data - SWOT Analysis

LINKEDIN api call using NODE.JS OAUTH module