# What algorithm is best suited to derive the best match between two people in a data set?

Say i have a large data set that contains the following data;

username,age,sex,music_genre,sports_genre,art_genre,rating
DanTheMan,25,male,rock,football,cubsim,50
LoopyLucy,23,female,pop,null,popart,76


I would like run through the whole data set and match two users based on ̶t̶a̶s̶t̶e̶s̶
genres and rating that are similar or closer then others like a best match. The gender does not need to be considered, What would be the best algorithm to acquire this result? There is an equal amount of users, Everyone will get a match.

I have taken a look into the stable marriage algorithm (Gale-Shapley) however I would appreciate someone else's suggestion and opinion.

Thanks!

• The first thing you need to do is define what exactly you mean by "best match". You also need to think about the features: do all features have equal weight? What to do with missing values? Can you pair two males or two females? If not: are there an equal number of males and females? After you have had a closer look at the data and have defined how to measure the quality of a match you can start looking at algorithms. It is probably worth reading about clustering and testing out a few algorithms to see which one works best for you (using the quality measure you chose earlier). Jun 30 '19 at 18:58
• What do you mean by "match two users based on tastes"? Do you mean that the two users are given as input and the output is a similarity score? Or that one user is given as input and the output is the most similar other user? Or the input is the whole dataset and the output is a list of pairs of similar users? Jun 30 '19 at 22:22
• Hey @Erwan thanks for your comment, The latter option is my desired result. I would like to put in a set of users (equal amount), and receive a list of users that the model thinks would 'enjoy' to be paired together. Scoring would be the genres they are interested in and the rating. Thanks again Jun 30 '19 at 22:50
• Thank you @louic for your comment, I have edited my question a little, I will read into clustering. Jun 30 '19 at 22:51