Match Analytics Resources

class soccermetrics.rest.resources.analytics.AnalyticsResource(resource, base_uri, auth)[source]

Represents an Analytics REST resource.

The Match Analytics resources controls access to advanced player and team analytics related to events in a football match and derived from basic match data.

Derived from resources.Resource.

EndpointURI()[source]

Construct URI of Analytics REST resource.

URI is of format /analytics/match/<match>/<resource>/.

Returns:URI of REST resource.
Return type:string
get(match, **kwargs)[source]

Retrieves a representation of Analytics REST resource.

Parameters:
  • match (integer) – Unique ID associated with football match.
  • kwargs (dict) – Collection of query parameters.
Returns:

Resource representation.

Return type:

Return value of Resource.get().

head()[source]

Retrieves header data of Analytics REST resource.

Returns:Header data.
Return type:Return value of Resource.head().
options()[source]

Retrieves documentation of Analytics REST resource.

If the status code is 200 (OK), returns the documentation. Otherwise, returns an error.

Link resources are not included in the documentation.

Returns:Resource documentation data.
Return type:Return value of Resource.options().
class soccermetrics.rest.resources.analytics.MatchAnalytics(base_uri, auth)[source]

Represents a Match Analytics REST resource (/analytics/match endpoints).

Attribute Description
state Match state
segment Match segments
tsr Match Total Shots Ratio