Skip to content
New Workbook
Sign up
Project: Data-Driven Product Management: Conducting a Market Analysis

You are a product manager for a fitness studio and are interested in understanding the current demand for digital fitness classes. You plan to conduct a market analysis in Python to gauge demand and identify potential areas for growth of digital products and services.

The Data

You are provided with a number of CSV files in the "Files/data" folder, which offer international and national-level data on Google Trends keyword searches related to fitness and related products.

workout.csv

ColumnDescription
'month'Month when the data was measured.
'workout_worldwide'Index representing the popularity of the keyword 'workout', on a scale of 0 to 100.

three_keywords.csv

ColumnDescription
'month'Month when the data was measured.
'home_workout_worldwide'Index representing the popularity of the keyword 'home workout', on a scale of 0 to 100.
'gym_workout_worldwide'Index representing the popularity of the keyword 'gym workout', on a scale of 0 to 100.
'home_gym_worldwide'Index representing the popularity of the keyword 'home gym', on a scale of 0 to 100.

workout_geo.csv

ColumnDescription
'country'Country where the data was measured.
'workout_2018_2023'Index representing the popularity of the keyword 'workout' during the 5 year period.

three_keywords_geo.csv

ColumnDescription
'country'Country where the data was measured.
'home_workout_2018_2023'Index representing the popularity of the keyword 'home workout' during the 5 year period.
'gym_workout_2018_2023'Index representing the popularity of the keyword 'gym workout' during the 5 year period.
'home_gym_2018_2023'Index representing the popularity of the keyword 'home gym' during the 5 year period.
# Import the necessary libraries
import pandas as pd
import matplotlib.pyplot as plt
# Start coding here
workout = pd.read_csv('data/workout.csv')
workout

# locate the global search for 'workout' at its peak
peak_workout = workout.loc[workout['workout_worldwide'].idxmax()]

# extract the year using the slicing method
year_str = peak_workout['month'][:4]
year_str
# Read csv file
df_keywords = pd.read_csv('data/three_keywords.csv')
df_keywords


# Create a line plot to visualise the data and obtain the answers
plt.figure(figsize=(14, 8))
plt.plot(df_keywords['month'], df_keywords['home_workout_worldwide'], label='home workout')
plt.plot(df_keywords['month'], df_keywords['gym_workout_worldwide'], label='gym workout')
plt.plot(df_keywords['month'], df_keywords['home_gym_worldwide'], label='home gym')
plt.xticks(rotation=90)
plt.legend()
plt.show()

peak_covid = 'home workout'
current = 'gym workout'
df_keywords
# Read CSV file
df_workout_geo = pd.read_csv('data/workout_geo.csv')
df_workout_geo

# Create a line plot to visualise the data and obtain the answers
plt.figure(figsize=(30, 15))
plt.bar(df_workout_geo['country'], df_workout_geo['workout_2018_2023'], label='Interest for workouts')
plt.xticks(rotation=90)
plt.legend()
plt.show()

top_country = 'United States'
# Read CSV file
vtl_home_workouts = pd.read_csv('data/three_keywords_geo.csv')
vtl_home_workouts

# Create a line plot to visualise the data and obtain the answers
plt.figure(figsize=(30, 15))
plt.rcParams.update({'font.size': 14})
plt.bar(vtl_home_workouts['Country'], vtl_home_workouts['home_workout_2018_2023'], label='Home Workout')
plt.bar(vtl_home_workouts['Country'], vtl_home_workouts['gym_workout_2018_2023'], label='Gym Workout')
plt.bar(vtl_home_workouts['Country'], vtl_home_workouts['home_gym_2018_2023'], label='Home-Gym Workout')
plt.xticks(rotation=90)
plt.legend()
plt.show()

home_workout_geo = 'Philippines'