Added type and state to competition filter. Refactor of tracking data calculations.