Skip to main content

Predicting future of Pakistan through social media: A Battle between PTI, 

By

Dr Mubarik Ali, 
Chairman,
Sustainable Development Advances (www.sdaint.org) 



Social media has exploded as a category of online discourse where common persons can create contents, share them, bookmark them, and publish them at a prodigious rate. Examples include, Facebook MySpace, Twietter, Digg, and Youtube. Two worldwide popular social media websites, Twitter and Facebook, demonstrate its explosive growth and profound influence. Both Twitter and Facebook are in the top 10 most-visited websites in the world according to Alexa ranking. According to a recent estimate, more than 2000 Millions users check their Facebook account on monthly basis, followed by Twitter, which has more than 300 Million active users. Furthermore Youtube is claimed to have more than 1500 Millions users and LinkedIn has more than 260 Millions users. Social media is rapidly changing the public disclosure in society due to its simplicity, ease of use, and speed and reach. Interest in social media, from individuals (especially youth) and businesses alike, is rising worldwide and it is setting trends and agendas in topics that range from the environment and politics to technology and the entertainment industry.


As more people offer up posts and tweets about their likes and dislikes, social media data can be constructed as a form of collective wisdom. This collective intelligence data, if extracted and analyzed properly, can lead to useful predictions of certain human related events. Such diction has great benefits in many realms, such as finance (predicting real-world outcomes), product marketing (consumer insights) and politics (predicting election outcomes as done by Nate Silver for US elections). Other researchers have also claimed that social media based predictions outperform some other traditional techniques such as surveys and opinions polls. In this regard, our social media prediction for Pakistan election should be more accurate than the recent television surveys and polls.



Pakistan is an emerging country having inchoate software industry. According to an estimate about 50 Millions people in Pakistan uses social media, most of them are youth between 18 to 35 years of age. The enormity of the information about Pakistan politics that propagates through large user communities presents an interesting opportunity for harnessing that data into a form that allows us to predict the future of a political party. We also build models to aggregate the opinions of the collective population and gain useful insights into their behavior, while predicting future trends of a specific political party. The success of fivethirtyeight, a website that made predictions of the US elections based social media data (http://fivethirtyeight.blogs.nytimes.com/) further strengthen our claim to make prediction for Pakistan election through social media.

As in Pakistan 2018’s election it is the first time most of the youth has registered for the votes, hence using their opinions about different political parties one can infer the success or failure of these parties.





Figure 1: Figure illustrating the percentage increase in the number of social media (Facebook) users in Pakistan (from June 2013 to June 2018). There has been tremendous increase in social media users (Source: statista.com).



In this article, we used Brandwatch social media monitoring software (www.brandwatch.com). We crawled data from major websites including Facebook, Twitter, Youtube, and other open social media forums (more than 100 websites in total) from Jan 2018 to June 2018. We used state-of-the-art sentiment (sentiment is the overall emotion of a customer towards a product, it can be positive showing positive mode/tone of the user, negative showing negative mode/tone of the user, and neutral where a user’s tone is not biased towards any of the emotion) analysis algorithms.


Volume Based Prediction


Volume is the total number of mentions (e.g. a text snippet representing description, comment, suggestion, etc.) scripted by social media users associated to a particular political party. Volume plays a major role in predicting events, for example, predicting the revenue a movie will make in the box office before release is estimated based on the total number of users/mentions being talked for that movie in Web.


The next figure shows the overall volume of the main political parties in Pakistan. There are total 242 thousands mentions. We observe that PTI is the most famous party over the social media and people are talking continuously about PTI, highlighted by spikes. Political anchor called it a huge success of PTI and steps towards election campaign of PTI.

* All dates have been hidden to omit any controversy. 



Figure 1: A snapshot of overall volume of main political parties in Pakistan from Jan 2018 to Apr 2018. There were about 242 thousands mentions during 3 months periods (Apr 2018 to July 2018). 42% mentions have negative sentiment whereas only 16% have positive sentiment (see footnote about sentiments). 


Figure 2: Volume of the mentions coming from Punjab (Pakistan). The figure has the same pattern as depicted by Figure 1.



Figure 3: Comparing the volume of different parties over social media for last three months.

Sentiment based Prediction:


The second analysis is the sentiment-based analysis. Sentiment is emotional tone of a sentence for a specific target. For example if our target is “PTI” the some sample sentences and sentiments are given the following table.


Table 1: describing how sentiment works Sentiments can be positive, negative, and neutral and they depend on the target. For example the tone of the sentence: “PTI is making good progress than PMLN” is good/positive for PTI and bad/negative for PMLN. We are more interested in collection of mentions having positive and negative sentiments.
Target
Sentence
Sentiment
PTI
PTI is making good progress than PMLN
Positive for PTI
PTI, PMLN
Nawaz Sharif has been disqualified by Supreme Court
Positive for PTI
PTI
PTI is run by master of U-turn (Imran Khan)
Negative for PTI
PTI
PTI is made by Imran Kahn
Neutral for PTI
PMNL
PTI is making good progress than PMLN
Negative for PMLN

Sentiment plays a major role in Stock market prediction. For example, researchers have used sentiment of the people to predict stock market trends (Forex market). Our sentiment predictor is very simple---we map the sentiment of people towards a political party as the success and failure of the party. The extensive analysis can be described into following main points:



Figure 4: Net sentiment of all mentions related to a specific political party. PTI is appearing to fade its good/positive sentiment over period of time (becoming more negative); however, the sentiment is getting better/positive from the month of Apr 2108 to July 2018. The sentiment of PTI is getting better than PMLN towards end of July 2018. PPP has the worse sentiment, which is consistently negative over the period of time. The sentiment of PMLN is improving over July 218, which can produce spike in a week.


1-    The general sentiment of Pakistani nation about all political parties is skewed towards negative. It shows the general despair of nation over all political parties---people believe that none of the active party can bring the real change in Pakistan.

2-    PTI has sentiment that is more neutral rather than negative showing nation trusts more over PTI compared to other parties. In other words, people want to give PTI a chance.

3-    The sentiment of PMLN and PPP is negative indicating Pakistani nation does not has any positive expectations from these parties. The sentiment of the PPP is worse compared to the rest.


The bottom line of this article is that we can predict the future of the Pakistan through social media using simple prediction algorithms. We used two simple prediction algorithms, volume based and sentiment based. The chief points of our analysis  can be underlined as follows:

1-    PTI has build good auspicious momentum in recent weeks and, if the momentum continues, PTI consistency has more chances of sweeping the elections based on our predicting algorithms.

2-    PMLN has close competition with PTI and can be considered the second favorable political party.

3-    PPP is the least favorable party in eyes of Pakistani nation and has less chance to win.



We will continue this analysis on bi-weekly basis. We will predict the probability by which a political party will win in major provinces of Pakistan.



Special Thanks to Brandwatch (www.brandwatch.com) for providing us valuable tool to analyze the data.





[1] Sentiment analysis is a well-studied problem in linguistics and machine learning. It is a classification problem, where a given text needs to be labeled as
Positive, Negative or Neutral based on its tone and context about a specific subject.

Comments

Popular posts from this blog

MSc Experience in ECS, University of Southampton, UK

This is what I wrote here ( http://blog.soton.ac.uk/studentblogs/author/mag208r/ ) for my MSc experience in ECS, University of Southampton UK. I did my MSc is Software Engg in 2007/08 session. " MSc experiences at ECS "You must answer this question": You will probably be wondering what this sentence has to do with my introduction. Well it is the sentence I say to everyone who complains about the difficulty of my name: "Mustansar" ‘Must-Ansar’ (Pronounced Must Answer). More frankly you can call me 'Musi', my nickname, and my friends call me by this name. I have been here in ECS for the last year. It has been an awesome experience with everything concerned: Campus, Labs, Lectures, Teachers, Friends, and our most hated 'Exams' and 'Course Works'...:). It is good to share the feelings I got since I started my course in MSc Software Engineering (Oct 2007). When I first came to the University of Southampton, the first month was s...

Malala YusufJai Shooting --- Who is who?

I was busy in my office, writing a software program to predict the stock market future trend using the historical data. The prediction problem is multifaceted and really hard, as the trend depends on a number of factors rather than the historical data; for example, on the news, blogs, social media campaign, a nd politics for example the stock market gambler can intentionally turn the whole market upside down to exploit some shares . The clock struck 12.00 noon, and to relax a bit, I opened the BBC website and was shocked to read that: “Malala has been gunshot by unknown people in Swat region ”. It was really disturbing--- Malala YusufJai , a young 14-years old bright student and activist, is considered as a national brilliance as she has earned international fame for  raising voice against Taliban oppression  in Swat. She became the voice of all Swati girls by writing a diary in the BBC Web-site, famous for her pen name “Gul Makai.” Who is responsib...