Calculate a new sort index for groups

calc_sort_index(x, active_group = NA)

Arguments

x

group or sftrack object

active_group

(optional), a new active group. If not included, defaults to the active group (if a c_grouping) or the group names