Data Analysis on Pink Tax in Toys

Posted on Apr 27, 2019

Β 

The skills the author demoed here can be learned through taking Data Science with Machine Learning bootcamp with NYC Data Science Academy.

GitHub LinkΒ  //Β Shiny.io Link // Kaggle Dataset //Β  Wiki Pink Tax


Intro

The "pink tax" is a form of gender-based discrimination, where products & services catered towards females are priced higher than those marketed to the opposite sex. Data shows this has been seen in everything from beauty products to clothes to toys.Β 

My project specifically focuses on the latter, analyzing a dataset of 10,000 Amazon toy records to see if I could find evidence of this phenomenon. I used Kaggle dataset, R for data analysis, Shiny & ggplot2 for visualization. Links to my code & app are above.

Data Analysis on Pink Tax in Toys

Data Cleaning

This initial step mostly involved cutting out unnecessary fields, converting columns to numeric, and removing rows where price were NA (as that was my primary metric for my hypothesis). Anything that could be converted to a factor was converted, for more efficient data loading.Β 

I also changed multi-level categories into the 2nd leaf, as that would provide still a level of detail while reducing the category types to a manageable 148 total categories (eg "Hobbies > Model Trains & Railway Sets > Rail Vehicles > Trains" would become "Model Trains & Railway Sets").

The dataset was split into two similar copiesΒ  - one that included all the verbose fields used for Gender Categorization, and one that was slimmer used for Data Visualization within the app itself.

Data Analysis on Pink Tax in Toys

Gender Categorization

To determine if a toy was marketed for girls vs boys, the code would look for matching keywords in the names, reviews or descriptions.

If "princess" was found, then the girly column would be marked as true. If "soldier" was found, then the boyish column would be marked as true. Depending on the what was in the girly or boyish columns, the ultimate designation would be girl, boy, or neutral (for cases where its neither or both).Β 

One of the features of this app is that it allows the user to select their own keywords, and thereforeΒ dynamicallyΒ customize the dataset, although core keywords (such as 'daughter' and 'son') will always be included.

Data Analysis on Pink Tax in Toys

Data and Stat Comparisons

After the dataset is updated, I would run an F-Test (for variance) and a two sample T-test (for comparing means) on the overall dataset of girl toys vs. boy toys, AND amongst all categories that had sufficient datapoints for comparison. The details are seen in the Boys Vs. Girls tab.

With just the core keywords, only 24 of the 148 total categories were analyzed, and with those, only 1 category was found with a p-value low enough to claim that the girl's toys were more expensive than the boy's toys.Β 

The highlights of the EDA & findings can be found in the infoboxes, or by seeing the boxplot or scatterplot details. The overall finding with the cord dataset was that the prices of boy toys was actually higher than the prices of the girl's toys.

Top 20 Analysis

The dataset also shows additional information in the Top 20 tab. Its interactive, allowing the user see how Category or Manufacturer is ranked by a variety of metrics ranging from count to popularity. The bars are filled with varying shades of blue or red to indicate a gender ratio within that subset as well.Β 

There are plenty of interesting observations here - what types of toys are most expensive (Vehicles & Accessories), or which manufacturers cater towards girls (Disney). Feel free to play around to see what other patterns are there with your customized dataset!

Future Considerations

There is a lot more to explore on this topic. If I had more time, I would want to refine the methodology on determining gender focus, possibly assigning a value based on keyword found frequency rather than a True or False.

I would also want to investigate other product sets off Amazon to see if evidence of Pink Tax can be found there, and seeing if gender-focused products tend to sell better than neutral products.Β 

Thank You For Reading =)

About Author

Katy Qian

I have an B.S. in Electrical Engineering & an M.S. in Information Systems Management, with 9 years in telecom working mostly as a RF Engineer designing cell phone towers, but eager to transition my Data Science career into...
View all posts by Katy Qian >

Leave a Comment

No comments found.

View Posts by Categories


Our Recent Popular Posts


View Posts by Tags

#python #trainwithnycdsa 2019 2020 Revenue 3-points agriculture air quality airbnb airline alcohol Alex Baransky algorithm alumni Alumni Interview Alumni Reviews Alumni Spotlight alumni story Alumnus ames dataset ames housing dataset apartment rent API Application artist aws bank loans 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 boston safety Bundles cake recipe California Cancer Research capstone car price Career Career Day citibike classic cars classpass clustering Coding Course Demo Course Report covid 19 credit credit card crime frequency crops D3.js data data analysis Data Analyst data analytics data for tripadvisor reviews data science Data Science Academy Data Science Bootcamp Data science jobs Data Science Reviews Data Scientist Data Scientist Jobs data visualization database Deep Learning Demo Day Discount disney dplyr drug data e-commerce economy employee employee burnout employer networking environment feature engineering Finance Financial Data Science fitness studio Flask flight delay gbm Get Hired ggplot2 googleVis H20 Hadoop hallmark holiday movie happiness healthcare frauds higgs boson Hiring hiring partner events Hiring Partners hotels housing housing data housing predictions housing price hy-vee Income Industry Experts Injuries Instructor Blog Instructor Interview insurance italki Job Job Placement Jobs Jon Krohn JP Morgan Chase Kaggle Kickstarter las vegas airport lasso regression Lead Data Scienctist Lead Data Scientist leaflet league linear regression Logistic Regression machine learning Maps market matplotlib Medical Research Meet the team meetup methal health miami beach movie music Napoli NBA netflix Networking neural network Neural networks New Courses NHL nlp NYC NYC Data Science nyc data science academy NYC Open Data nyc property NYCDSA NYCDSA Alumni Online Online Bootcamp Online Training Open Data painter pandas Part-time performance phoenix pollutants Portfolio Development precision measurement prediction Prework Programming public safety PwC python Python Data Analysis python machine learning python scrapy python web scraping python webscraping Python Workshop R R Data Analysis 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 seafood type Selenium sentiment analysis sentiment classification Shiny Shiny Dashboard Spark Special Special Summer Sports statistics streaming Student Interview Student Showcase SVM Switchup Tableau teachers team team performance TensorFlow Testimonial tf-idf Top Data Science Bootcamp Top manufacturing companies Transfers tweets twitter videos visualization wallstreet wallstreetbets web scraping Weekend Course What to expect whiskey whiskeyadvocate wildfire word cloud word2vec XGBoost yelp youtube trending ZORI