Nearest dataset

#1
Hi everybody. I have a question for my phD thesis.
i simplified my problem with a sample:
for example we consider having 100 students in a classroom and listed their scores in math, physics, biology, geography, history and chemistry examinations (for example student1: math=50, physics=80, biology=40, geography=55, history=65, chemistry=80. so way 100 students are listed). And consider we have a 101th student as referance, out of the dataset. question is here, i want to find the nearest student from the 100 students, to the referance student. Most similar one by math, physics, biology, geography, history and chemistry skills. Which analys i would use to find the most similar, the closer one and how? thank you for help
 

hlsmith

Less is more. Stay pure. Stay poor.
#2
There are matching algorithms where you usually set the calipers, but you just want to match the single observation right. I think there is an R package called Matchit by Gary king et al.

Otherwise it seems like you could just minus the obs values from the others and find the closest, I am guessing there is a distance formula you could use.