Data Interview Qs - K-means cluster plot

InterviewQs

K-means cluster plot

Data Analysis Python Pandas Data Manipulation Data Visualization K-means Clustering

Forward this email to a friend or colleague and challenge them to solve it.

Hi, 

Suppose you have the following dataset which contains (1st tab) a list of items purchased by a given user, (2nd tab) a mapping which maps the item_id to the item name and price, (3rd tab) a matrix that formats data from sheet 1 into a matrix with users in rows and the number of each item_id purchased in columns.

With this data, we want to see if we can cluster types of groceries that are typically purchased together. In a previous question, for this data set, we wanted to build plots to look at n=3, 5, and 7. Knowing this, can you create a function that allows us to input the number of clusters and returns a plot with the potential clusters using Principal Component Analysis (PCA)?

Answer will be written in Python for premium users.



 

You’ve accumulated 208 questions since joining our email list. Create a premium account to access detailed solutions to each problem (including this one) + our new Case studies.


Was this email forwarded to you? You can join our list here to receive questions

How did you like today's question?

15411 Boischatel, Montreal, QC, H9H1Y7, Canada
Don't want to get these emails anymore? We'll forgive you if you unsubscribe

Older messages

Biased coin toss

Friday, October 29, 2021

Python, Statistics, Simulation, Probability Theory, InterviewQs Biased coin toss Python Statistics Simulation Probability Theory Forward this email to a friend or colleague and challenge them to solve

Counting the distance between words in Python

Wednesday, October 27, 2021

Python, String Manipulation, InterviewQs Counting the distance between words in Python Python String Manipulation Forward this email to a friend or colleague and challenge them to solve it. Hi, Suppose

Chocolate Bar Reviews

Monday, October 25, 2021

SQL, Database Querying, Rank Function, Window Function, External Dataset, InterviewQs Chocolate Bar Reviews SQL Database Querying Rank Function Window Function External Dataset Forward this email to a

Chipotle order prices

Friday, October 22, 2021

Data Analysis, Python, Pandas, Data Manipulation, External Dataset, InterviewQs Chipotle order prices Data Analysis Python Pandas Data Manipulation External Dataset Forward this email to a friend or

Auto component quality

Wednesday, October 20, 2021

Statistics, T-test, Interpreting P-values, InterviewQs Auto component quality Statistics T-test Interpreting P-values Forward this email to a friend or colleague and challenge them to solve it. Hi,

You Might Also Like

New Alpine.js Sort plugin, Laravel 11.5, and more - №510

Sunday, April 28, 2024

Your Laravel week in review ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏

This Week's Daily Tip Roundup

Sunday, April 28, 2024

Missed some of this week's tips? No problem. We've compiled all of them here in one convenient place for you to enjoy. Happy learning! iPhoneLife Logo View In Browser Your Tip of the Day is

DeveloPassion's Newsletter #164 - A Thousand Fans

Sunday, April 28, 2024

Edition 164 of my newsletter, discussing Knowledge Management, Knowledge Work, Zen Productivity, Personal Organization, and more! Sébastien Dubois DeveloPassion's Newsletter DeveloPassion's

Nobody Likes a Know-It-All: Smaller LLMs are Gaining Momentum

Sunday, April 28, 2024

Phi-3 and OpenELM, two major small model releases this week. ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏

Retro Recomendo: Music

Sunday, April 28, 2024

Recomendo - issue #408 ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏

Your Phone’s Other Number 📱

Saturday, April 27, 2024

Let's talk about your phone's IMEI number. Here's a version for your browser. Hunting for the end of the long tail • April 27, 2024 Today in Tedium: As you may know, Tedium is a blog and/or

🕹️ How to Play Retro Games for Free on iPhone — Why I Can't Live Without an eReader

Saturday, April 27, 2024

Also: Anker MagGo (Qi2) Power Bank Review, and More! How-To Geek Logo April 27, 2024 📩 Get expert reviews, the hottest deals, how-to's, breaking news, and more delivered directly to your inbox by

Weekend Reading — The Bob Ross of programming

Saturday, April 27, 2024

This week we use coffee tasting as our design practice, get as close to and as far away from the metal as possible, find an easier way to write documentation, discover why Google Search is getting so

Issue #538: All the Jam entries, Panthera 2, and Tristram

Saturday, April 27, 2024

Weekly newsletter about HTML5 Game Development. Is this email not displaying correctly? View it in your browser. Issue #538 - April 26th 2024 If you have anything you want to share with the HTML5 game

Daily Coding Problem: Problem #1424 [Easy]

Saturday, April 27, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Microsoft. Implement a URL shortener with the following methods: shorten(url) , which