socceraction.spadl.opta.convert_to_actions#

socceraction.spadl.opta.convert_to_actions(events, home_team_id)#

Convert Opta events to SPADL actions.

Parameters
  • events (pd.DataFrame) – DataFrame containing Opta events from a single game.

  • home_team_id (int) – ID of the home team in the corresponding game.

Returns

actions – DataFrame with corresponding SPADL actions.

Return type

pd.DataFrame