Skip to content

HiAudrey/Elon-Musk-s-Tweets-Analysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 

Repository files navigation

Elon Musk's Tweets Analysis

Overview: The objective of this project was to perform word frequency analysis on Elon Musk's tweets from 2017 to 2021. Two methods, Term Frequency (TF) and Term Frequency-Inverse Document Frequency (TF-IDF), were employed to gain insights into Musk's Twitter activity during these years.

Data Description: The dataset comprises Elon Musk's tweets from 2010 to 2022, with the analysis focusing on the years 2017-2021. Each year's tweets are treated as a separate document for analysis. Get data here: https://www.kaggle.com/datasets/ayhmrba/elon-musk-tweets-2010-2021?resource=download&select=2017.csv

Results and Insights:

  • 2017: Musk frequently used the term "gt," likely referring to the concept of grand tourer cars. This aligns with his interest in luxury and high-performance automobiles, notably Tesla.

  • 2018: Musk was researching "flamethrowers," possibly related to SpaceX projects. This suggests his involvement in innovative technologies, even beyond electric vehicles.

  • 2019: Musk mentioned "amp," "tesla," and "starship," reflecting his focus on amplifiers, Tesla (his company), and SpaceX's Starship project, respectively.

  • 2020: Musk's tweets featured terms like "covid," "high," and "self," indicating discussions related to the COVID-19 pandemic, high-performance technologies, and possibly self-improvement.

  • 2021: Musk extensively discussed "ai," emphasizing his interest in artificial intelligence and its implications.

Additionally, Musk's tweets often contained numerical data, highlighting his analytical and data-driven communication style.

Insights from Text Analysis:

  1. Word Frequency Analysis:

    • Term frequencies for each year were computed and normalized, excluding stopwords.
    • The top 10 words for each year were determined based on their frequency.
  2. Word Frequency Histograms:

    • Histograms were plotted to visualize word frequencies for each year, providing a clear overview of the most common words in Musk's tweets.
  3. Zipf's Law:

    • Zipf's Law was demonstrated by plotting log-log graphs of word frequencies versus ranks for each year, confirming the presence of a power-law distribution.
  4. TF-IDF Analysis:

    • TF-IDF was utilized to identify the five most important words in each year's tweets. This method offered deeper insights into the significance of specific words within the context of Musk's tweets.

Conclusion: The analysis provided valuable insights into Elon Musk's Twitter activity, showcasing his diverse interests ranging from automobiles and technology to artificial intelligence. The use of TF and TF-IDF methods enabled a comprehensive exploration of Musk's social media communication style, shedding light on the key themes dominating his tweets during the specified years. Emojis, though not explored in this analysis, could present an interesting avenue for future investigations, showcasing the richness of language in digital communication.

About

Get Insights from Elon Musk's Tweets!

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published