Indian Elections 2019 Analysis(EDA)
Indian Lok Sabha Elections:
The Lok Sabha elections in India are held every five years to elect members of the lower house of India’s bicameral parliament. These elections are conducted by the Election Commission of India, an independent body responsible for overseeing the conduct of all elections in the country.
All citizens of India who are 18 years of age or older are eligible to vote in the Lok Sabha elections. The election process usually takes place over a period of several weeks, with polling held in different parts of the country on different days. The voter turnout in these elections is typically high, with a large percentage of eligible voters casting their ballots.
The political parties and coalitions that win the most seats in the Lok Sabha are called upon to form the government. The leader of the party or coalition that wins the most seats is appointed as the Prime Minister of India.
The latest elections were held in 2019 next general election is due to be held in 2024.
Lok Sabha Elections 2019
The 17th Lok Sabha election was held in India in April-May 2019 to constitute the 17th Lok Sabha or lower house of India’s bicameral parliament.
The polling was conducted in seven phases, from April 11 to May 19, 2019. The results of the election were announced on May 23, 2019.
The Bharatiya Janata Party, led by Prime Minister Narendra Modi, won the election, with 303 of the 543 seats in the Lok Sabha. The Indian National Congress, the main opposition party, won 52 seats, while other parties and alliances won the remaining 188 seats.
The Task:
The task was to compile the election data from freely available data on the internet, clean the data so that to run an analysis on the same, and do an analysis to get some of the important insights from the Loksabha elections held in 2019. Further part of this is to use this data, and analysis to predict the winning chance of a given candidate.
The Process:
About Data:
This data was scraped from the website of myneta.info to get the personal information of each candidate (as per their own sworn affidavits) and the website of the Election Commission of India to get the data about the votes received. Later, merged both these datasets to create this comprehensive dataset. Only the candidates who secured at least 1% of the total votes polled in their constituency have been included. You can find this data set at Link There are 2263 entries in the CSV file with 19 columns, the columns can be divided as:
Basic Candidate Details:
- STATE
- CONSTITUENCY
- NAME
- WINNER
- PARTY
- SYMBOL
- GENDER
- CRIMINAL CASES
- AGE
- CATEGORY
- EDUCATION
- ASSETS
- LIABILITIES
Voting Details:
- GENERAL VOTES
- POSTAL VOTES
- TOTAL VOTES
- TOTAL ELECTORS
- TOTAL VOTES POLLED
- TOTAL ELECTORS
Data Preprocessing:
- Data Cleaning
Checking For Null Values
Checking For Duplicate Rows
Cleaning the Column Names
Clean the ASSETS and LIABILITIES column (Rs 30,99,414\n ~ 30 Lacs+ => 3099414)
Remove \n from the values of EDUCATION columns
EDA (Data Analysis Results):
Please Go through the ipython file for more in-detail analysis, below are some key details:
Statewise distribution of the Constituencies all over India: (Chech the graph in the notebook)
UP has HIghest Constituencies i.e. 80, MH has 48 so on.
Statewise distribution of voting percentage all over India: (Chech the graph in the notebook)
Lakshadweep has highest voting percentage i.e. 83.75
Constituency vs Statewise participation for the most contesting Political Parties (Chech the graph in the notebook)
BJP Contested on 420 Constituencies accross 33 states
INC Contested on 413 Constituencies accross 35 States
Which party won the most constituencies: (Chech the graph in the notebook)
BJP won on 300 Seats
INC won on 52 Seats
Party Wise vote share: (Chech the graph in the notebook)
BJP got 38.5% vote share
What has been the general Win vs Loss relationship for the Parties:
BJP won 300 and lost on 120 Seats
INC won 52 and lost on 361 Seats
DMK won has contested on 23 seats and won all
What is the Gender Ratio of the Contestants? Also the Gender Ratio of the Winners?
1760 Male candidates contested out of which 463 won
258 Male candidates contested out of which 76 won
Educational Qualification of our politicians: (Chech the graph in the notebook)
25 % are Post Graduate
24 % are Graduate
Candidate and Winner Assets: (Chech the graph in the notebook)
88.3% i.e. 475 MPs have assets in Crores
11.7% i.e. 63 Mps have assets in lakhs
Category-wise Candidates:
General: 399
SC: 85
ST: 55