calc_trackInd function

Calculate the index of the first observation of each track based on an ID variable