Skip to content

Measure minutes played in and out of possession #476

@lodevt

Description

@lodevt

The current MinutesPlayedAggregator (see here) calculates a general MinutesPlayed and optionally also a MinutesPlayedPerPosition. I think it would make sense to extend this to also calculate MinutesPlayerPerPossessionState, which would provide minutes played for three possession states:

  • in possession
  • out of possession
  • ball dead

The existing ball_state and ball_owning_team properties can be used to extract the necessary information.

Example data structure:

class PossessionState(Enum): 
    IN_POSSESSION = 'in-possession'
    OUT_OF_POSSESSION = 'out-of-possession'
    BALL_DEAD = 'ball-dead'

class MinutesPlayedPerPossessionState(NamedTuple):
    player: Player
    possession_state: PossessionState
    duration: timedelta

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions