US Airlines on Twitter

Fred Zeng
Posted on Jun 28, 2019


As technology grows and globalization develops, more and more consumers are using airplanes as their mode of transportation. With so many choices when it comes to flying, and so many airlines in the U.S. competing with each other, it is valuable to analyze the feedback given by consumers on Twitter. This study therefore takes this data set from Kaggle, with more than 14,000 tweets during the month of February 2015 over 6 major U.S. airlines. This data includes an overall rating, which can be negative, positive or neutral, along with their comments. The RShiny visualization can be viewed at and the code at


First I created a graph that shows the difference in quantity of reviews by three levels of rating. We can see that most of the tweets were negative. After that, I created two graphs to visualize how each individual airline performs. We can see that United Airlines has the most reviews but also has the highest negative percentage rate, while Virgin America has the fewest reviews but also the lowest negative rate.

By Airlines

Next, I conducted an analysis on each airline over three different charts in order to visualize passengers' reviews from three different perspectives.

By Words

After that, I aggregated keywords from each airline's comments to visualize the key reasons people didn't enjoy their experience. First I conducted a word count for each airline, and then built a heat map, followed by word clouds of the negative reviews. 

By Location

Following that, I visualized the aggregation of IP addresses that came with the data set with a map to identify where users are located. We can see that  the majority of users are from North America, some are from Europe, and a small amount from Southeast Asia. 


With this project, I was able to gain some key insights:

  • Most Internet users did not enjoy their experiences with major US airlines.
  • The best airline of the six is Virgin America, and the worst is United Airlines.
  • The top three reasons for negative reviews are bad customer service, delays, and cancellations.

The last insight is particularly important, as to improve ratings and customer retention, I would advise airlines to focus on identifying why poor service, delays, and cancellations occur. Indeed, with more time, that is where I would take this project: I would expand my data set and perform statistical regressions to help narrow down those root causes.

About Author

Fred Zeng

Fred Zeng

Fred received his M.S. in management and systems with a concentration in database technology from New York University. He was also a business and website analyst intern at NYU, for his research, he designed and conducted data testing...
View all posts by Fred Zeng >

Leave a Comment

No comments found.

View Posts by Categories

Our Recent Popular Posts

View Posts by Tags

#python #trainwithnycdsa 2019 airbnb Alex Baransky alumni Alumni Interview Alumni Reviews Alumni Spotlight alumni story Alumnus API Application artist aws beautiful soup Best Bootcamp Best Data Science 2019 Best Data Science Bootcamp Best Data Science Bootcamp 2020 Best Ranked Big Data Book Launch Book-Signing bootcamp Bootcamp Alumni Bootcamp Prep Bundles California Cancer Research capstone Career Career Day citibike clustering Coding Course Demo Course Report D3.js data Data Analyst data science Data Science Academy Data Science Bootcamp Data science jobs Data Science Reviews Data Scientist Data Scientist Jobs data visualization Deep Learning Demo Day Discount dplyr employer networking feature engineering Finance Financial Data Science Flask gbm Get Hired ggplot2 googleVis Hadoop higgs boson Hiring hiring partner events Hiring Partners Industry Experts Instructor Blog Instructor Interview Job Job Placement Jobs Jon Krohn JP Morgan Chase Kaggle Kickstarter lasso regression Lead Data Scienctist Lead Data Scientist leaflet linear regression Logistic Regression machine learning Maps matplotlib Medical Research Meet the team meetup Networking neural network Neural networks New Courses nlp NYC NYC Data Science nyc data science academy NYC Open Data NYCDSA NYCDSA Alumni Online Online Bootcamp Online Training Open Data painter pandas Part-time Portfolio Development prediction Prework Programming PwC python python machine learning python scrapy python web scraping python webscraping Python Workshop R R language R Programming R Shiny r studio R Visualization R Workshop R-bloggers random forest Ranking recommendation recommendation system regression Remote remote data science bootcamp Scrapy scrapy visualization seaborn Selenium sentiment analysis Shiny Shiny Dashboard Spark Special Special Summer Sports statistics streaming Student Interview Student Showcase SVM Switchup Tableau team TensorFlow Testimonial tf-idf Top Data Science Bootcamp twitter visualization web scraping Weekend Course What to expect word cloud word2vec XGBoost yelp