determine position in the subcategories array based on