collection_stats
Counts and averages loaded Spotify playlist tracks grouped by decade, artist, genre, or month, optionally split by a second dimension, to produce chartable summary tables.
Instructions
Counts and averages of the loaded playlists grouped by one dimension (optionally also split by a second one), as a small table you can chart. Examples: decade x playlist, top 20 artists, tracks per genre family, additions per month, one artist's albums (filters.artist).
Args: group_by: decade, year, artist (primary), album, genre (exact tags), genre_family, playlist, month_added or popularity_bin (steps of 5). split_by: optional second dimension from the same list; one row per group x split value. metrics: any of unique_tracks, entries, hours, avg_popularity, share (% of the selection's unique tracks). Default: unique_tracks and share. filters: narrow the tracks first (same filters as find_tracks). limit: groups to return, biggest first (default 50, max 500). Time dimensions and popularity bins are returned in order.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| filters | No | ||
| metrics | No | ||
| group_by | Yes | ||
| split_by | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |