added near neighbour script