python - Nearest Neighbors algorithm with timestamp -


i have .txt file 3 dimensions. x,y,time. file looks this: "10 10 12:00" many more points , times under it. have found nearest points x,y values need finding nearest neighbors time involved.

for example, "what's closest point "10 10"? have point in file "11 11", closest point.

now time added:

what closest point "10 10 12:00": "11 11 22:00" or "15 15 12:05". format "xvalue, yvalue, time".

any nn algorithm depends on distance measure.

so need decide how can calculate distances between points including times , that's part of problem @ hand. best way use ordinal distance between points introduction of penalty using difference in times.

but there no 'single answer' - need develop distance measure based on specific problem trying solve.


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -