top of page
Search
Writer's pictureTim Beecher

2021: A Year In Review via Google Trends

The year 2021 was indeed a crazy one. The world saw all sorts of events come and go as each day passed. Some of them suddenly rocked the world while others remained firmly in the back of our minds months on end. At least that was how my experience was. I wonder if others felt that same way....


Last year, a data visualization expert by the name of Roshaan Khan published a stunning visualization that captured the events of 2020 using the date from Google Trends that year. His product quickly went viral through Reddit, Twitter, LinkedIn and was even crowned Tableau's best visualization of the day.




I wanted to recreate and improve upon this data visualization using the events of 2021. I used Excel, Python and Tableau to create this. I primarily used Excel was used to hold the data frame of the events, Python to manipulate the dataset and Tableau to create the final visualization.


The first thing I did was determine what I felt were the significant events of 2021 and locate their search data through Google Trends. Whenever you search for a term using Google Trends, it gives you a few pieces of information one of which is how popular the search term was over time using a normalized index of 0-100. The limitation here is that you can only compare up to 5 search terms at a time and the 0-100 are normalized across the terms not individually. So this visulization will be able to give us a proper comparison over multiple search terms.


I came up with a list that I made an excel file for and also gave each a sub category so I could further classify them in the visualization. At this point I had the choice to manually pull each search term's data from Google Trends or I could try to automate it. I deployed a Python script using the pytrends library that allowed me to extract and manipulate the Google Trends data.


Here is what that script looked like:

After I went through this, the excel spreadsheet I produced had the search terms, their category, when they were popular and a date.



The final step was to upload this excel sheet into Tableau as raw data. Once that was connected, I first used the Gant chart designation starter and then changed the visual to an area line chart. This allowed me to view each of the search terms in this area chart fashion. I added a color as the category from the excel file and then created a filter using the when popular column in ascending order. This way it showed more popular search terms from the beginning of the year such as Biden at the top, and then more popular search terms near the end of the year such as Ghislaine Maxwell near the bottom. Ultimately this is what it turned out as:



It was interesting to me to see how different events or people in some cases were more popular at different times of the year. For example, Taylor Swift's searches shot up near the end of 2021 around the time she had released her album Red: Taylor's Version. Also interesting to me was in the crypto space. Bitcoin was more searched in the beginning of the year whereas NFTs are more searched near the end of 2021. Definitely something I want to keep an eye on and possibly do projects in that space in the future.


8 views0 comments

コメント


Post: Blog2_Post
bottom of page