The world’s leading publication for data science, AI, and ML professionals.

How to Use Data Studio to Research and Visualize Your Medium Stats

A step-by-step beginner-friendly tutorial to better understand the performance and engagement of your articles

Photo by Lukas Blazek on Unsplash
Photo by Lukas Blazek on Unsplash

Data Science is exciting. Everyone should practice it – the more, the better. Sometimes, though, practicing data science is hard for beginners as it involves a lot of learning and playing with data, which might not always be user-friendly. In the worst case, your project has nothing to do with your day-to-day, making the motivation to complete it harder to come by.

Inspired to turn the tide around for all the beginner data scientists, I devised a friendly introduction to Google Data Studio, using Medium Stats Data.

Google Data Studio is an easy-to-use, free, and powerful tool for Data Visualization, which allows you to build dynamic and interactive reporting dashboards. It is widely used in many industries, amongst which digital marketing, so is useful to add to any young entrepreneur’s toolkit.

It’s also quite fun to play with.

So, in the following sections, I present a step-by-step Data Studio Tutorial for Data Studio enthusiasts, absolute beginners, and writers, who want to look at something nicer than a bland old stats table every month, week, day, or every few hours, if you have no self-control like me.

To provide a brief overview, we will first scrape our data in a Google Spreadsheet, then import it in a Data Studio report, create a few calculations here and there, and visualize it.


A step-by-step tutorial on creating your Medium stats Data Studio report

1. Install Medium Enhanced Stats.

Medium Enhanced Stats is a Chrome extension that gives your total reach and summary stats of your articles (and responses).

The best thing about it is that it allows you to download your data as a .csv spreadsheet.

So, how can you get your Medium Stats?

Click on the ‘save’ button to download your data.

Download your data as a .csv from Medium Enhanced Stats User Interface. Image by Author
Download your data as a .csv from Medium Enhanced Stats User Interface. Image by Author

2. Load your Medium Stats data in a Google Sheets Spreadsheet.

The easiest way is to go to Gooogle Docs’ Spreadsheets URL and create a new spreadsheet.

Access Google Spreadsheets and create a new spreadsheet. Image by Author
Access Google Spreadsheets and create a new spreadsheet. Image by Author

Next, import the Medium Stats CSV we downloaded a second ago.

Click on the Import button.

Import your data in the Google Spreadsheet. Image by Author
Import your data in the Google Spreadsheet. Image by Author

Select the Medium Stats .csv file from your device and upload it.

Upload your Medium Stats .csv Image by Author
Upload your Medium Stats .csv Image by Author

Tune in the file import recommendations.

Tune in the import settings. Image by Author
Tune in the import settings. Image by Author

Check whether the import has been successful, and add an extra column ‘type’, which will be used to demonstrate the content-type – response or article.

Medium Enhanced Stats naturally splits up the data in articles (on top of the spreadsheet) and responses (at the bottom), so what you need to do is:

  • create an extra column type
  • type and drag ‘article’ or ‘response’ accordingly to label the entries in the type column
  • remove any empty rows (typically, there will only be one empty row, splitting the articles from the responses)
Format your spreadsheet as shown. Image by Author
Format your spreadsheet as shown. Image by Author

Now, your spreadsheet is ready for import in Google Data Studio.

Let’s switch over to there.


3. Create a Google Data Studio report and load your data.

Create a profile or log into Google Data Studio.

Create a Data Studio Report. You might be asked to agree to the Terms and Conditions of Data Studio and tune in your marketing preferences.

Create a Data Studio Report. Image by Author
Create a Data Studio Report. Image by Author

Now, let’s add data to the report.

Connect Data Studio to Google Sheets by giving the relevant permissions and authorizations for data access.

Connect to Google Sheets. Image by Author
Connect to Google Sheets. Image by Author

Then, add your Medium Stats SpreadSheet.

Add the data to your Data Studio Report. Image by Author
Add the data to your Data Studio Report. Image by Author

You will likely receive an additional warning that you are about to add the data to your report, but go ahead and click ‘add data’ once again.

Voila!

Your Medium Stats data is now in a Data Studio Report, ready to be visualized. Let’s take a quick tour of the user interface and do some cosmetic prep for our report.

User Interface Overview of a Data Studio Report. Image by Author
User Interface Overview of a Data Studio Report. Image by Author

Now, let’s visualize our data.


4. Create a Pie Chart to visualize your articles and response counts.

One of the things I want to visualize is the ratio between the articles I published and the responses I have given to other articles.

An easy way to visualize this is through a pie chart.

We can create this by adding a chart, selecting the chart type, and choosing to display the ‘type’ column through it. Previously, we created two types of entries in the type columns: Articles and Responses, so these can be beautifully visualized now.

Create a pie chart in Data Studio. Image by Author
Create a pie chart in Data Studio. Image by Author

5. Create a count for the total reads, views, claps, and posts.

In order to measure the total number of any of the given metrics, we must create a calculated field.

To do this we will select the ‘scorecard’ chart type from the chart field.

Then we can enter a formula, as illustrated in the image below.

  • For the number of posts, we will use the record countmetric.
  • For the total number of views, we will use the sum of views
  • For the total number of reads, we will utilize the reads column.
  • To calculate the total number of fans, we can use the sum of upvotes
  • Finally, total claps are the sum of claps.
Create Scorecards, using the calculated metrics function in Data Studio to visualize total reads, views, claps, and fans. Image by Author
Create Scorecards, using the calculated metrics function in Data Studio to visualize total reads, views, claps, and fans. Image by Author

6. Create a bar chart to view your top-performing articles.

Now that we have our scorecards, let’s visualize our top-performing articles.

For this purpose, we can utilize the dimensions we just created for reads and views, and plot them against the titles.

Insert a bar chart and select titles as the dimension. Then select the metrics you want to plot. I chose reads and views.

Finally, it’s very important to adjust the styling settings, so the chart is readable. For example, some things to note to achieve the displayed chart are:

  • choose appropriate (preferably contrasting colors)
  • choose the number of bars you want to display
  • ensure you show the data labels to help you with your analysis
  • make sure to show a single axis.
Create a bar chart to study your top-performing articles. Image by Author
Create a bar chart to study your top-performing articles. Image by Author

7. Create a line bar chart to visualize the articles with the most engagement and fans.

Add another bar chart to visualize engagement and fans to rank articles.

This time we want to add a line chart.

If you are following step-by-step, your dimension should already be set as the title, select the metrics upvotes and claps, and sort by upvotes.

Next, go to the Style section and adjust the following settings:

  • adjust the thickness of the line, and select an appropriate line color
  • show data labels
  • select an appropriate number of data points to show
  • show axes title
  • enable log scale for better visibility
Create a line bar chart to view your articles' engagement and fans. Image by Author
Create a line bar chart to view your articles’ engagement and fans. Image by Author

As a bonus, to improve the completeness of the report, add a footer, explaining how the data was extracted and from where.


8. Add titles to all charts and view the final report.

Use the Text function at the top to add titles to each chart and style them appropriately.

Add titles to charts, using the text function. Image by Author
Add titles to charts, using the text function. Image by Author

Finally, go to the top-righthand corner to view your report.

View your report. Image by Author
View your report. Image by Author

Here is how the final version of my report looks like.

The final version of the report. Image by Author
The final version of the report. Image by Author

Takeaway

The best thing about Google Data Studio is that it is dynamic, based on the data provided. A simple refresh of the report page, if the connected spreadsheet has been updated with new data, will be enough to update the entire report view.

In my opinion, this approach offers a much better user experience in visualizing Medium Stats and tracking our progress as writers on the platform.

Another fantastic thing is reports can also be saved as templates and shared with others. If you are feeling like this year has been hard enough already, and you don’t feel like learning Data Studio to better visualize your stats, here is a link to the report, introduced in this article, which can be downloaded and used as a report template. To do so, simply log into your account, open the link, copy the report, and use it as a template, which you can sync up with your Medium Stats data.

While this is a very fundamental introduction to the capabilities of Data Studio, I trust there can be other insightful, as well as more advanced ways to visualize this dataset. Experiment and customize the template as you see fit.

In future articles, I will show how to create multi-page reports, with data from other sources to demonstrate the relationship between earnings, engagement, reads, and views.

(editor’s note: The article promised has just been published. Here is a link to V2.0 of my Medium dashboard and a link below to my 1-year on Medium article, discussing the relationship between earnings, engagement, reads, and views 🚀 )

I Analyzed My 1-Year Writing Journey using a Fancy Dashboard – Time to Bust Some Myths


4 Limitations of Google Data Studio That Advanced Users Should Watch Out For


Related Articles