add function to calclute Recall. Fuction of calculate distance matrix seems to be poor in terms of prediction.