Hi everyone,
I'm doing a search of a database using algorithms to tell the user how accurate the results are.
I have 2 search algorithms I'm working with - spreading activation which I have no idea how to implement and K-Nearest neighbour which I have the following problem with:-
I have my database set up with lots of foreign keys so each hair colour, eye colour etc.. has a number (brown = 1, black = 2...)
then the main table has (for example) Peter, 1, 2, 3, 4, 5 (Peter, hair = brown, eyes = green, .... and so on coz each number is a field)
So, I use the KNN to find the distance between 2,1 and 1,1 etc...
I'm looking for brown hair and green eyes (2,1) and the nearest is black hair, green eyes (1,1)
the problem is I don't know how to assign the numbers in the database, to a number on a graph!
I hope that makes sense!
If anyone can help me, please, please do! any ideas, suggestions and advice are welcome! Especially for Spreading Activation coz I really don't know how to use that!
Thanks.
Cathy.