G
Guest
I have a tracking program that outputs 2 columns ([x] and [Y]) that represent
the position of an object on a 2D plane through time. Time is designated by a
third column [frame] which can have a value from 1 to however many frames
were tracked (n). I need to calculate new fields that would be equal to
(x for [frame]=2) - (x for [frame]=1), (x for [frame]=3) - (x for
[frame]=2), up to (x for [frame]=n) - (x for [frame]=n-1), and (y for
[frame]=2) - (y for [frame]=1), (y for [frame]=3) - (y for [frame]=2), up to
(y for [frame]=n) - (y for [frame]=n-1) (so that i can use Pythagoras' theorm
to caluclate the distance the object has moved between each time step). The
number of frames tracked (n) is different for different objects.
Does anyone have any idea how to do this in a query?
the position of an object on a 2D plane through time. Time is designated by a
third column [frame] which can have a value from 1 to however many frames
were tracked (n). I need to calculate new fields that would be equal to
(x for [frame]=2) - (x for [frame]=1), (x for [frame]=3) - (x for
[frame]=2), up to (x for [frame]=n) - (x for [frame]=n-1), and (y for
[frame]=2) - (y for [frame]=1), (y for [frame]=3) - (y for [frame]=2), up to
(y for [frame]=n) - (y for [frame]=n-1) (so that i can use Pythagoras' theorm
to caluclate the distance the object has moved between each time step). The
number of frames tracked (n) is different for different objects.
Does anyone have any idea how to do this in a query?