recparam: Get Local Recommendations

Description Usage Arguments Value

Description

This is the wrapper function to the Listen Local Demo recommendation system.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
get_local_recommendations(
  playlist_id = "6KHw5aZWWsmRqpT7o290Mo",
  target_nationality = "sk",
  target_release = "sk",
  recommendation_type = "artists",
  limit = 20,
  n_rec = 4,
  silent = TRUE,
  authorization = NULL,
  listen_local_artist_data = "not_included/listen_local_artists.rds",
  artist_distance_data = "not_included/artist_distances.rds",
  local_genre_table_path = "not_included/local_genre_table.rds",
  artist_genre_table_path = "not_included/artist_genre_table.rds"
)

Arguments

playlist_id

A Spotify playlist id. This playlist serves as the basis of the recommendation.

target_nationality

Defaults to "sk". The nationality id of the recommendation candidate artists, if necessary.

target_release

Defaults to NULL. The country of origin of the recommendation candidate tracks, if necessary.

recommendation_type

Defaults to 'artists', can be 'release' or 'both'.

limit

Number of playlist items used for recommendation seed.

n_rec

Number of required recommendations. (Maximum value, may not be fulfilled.)

silent

Defaults to TRUE.

authorization

Defaults to NULL when get_spotify_access_token is invoked.

listen_local_artist_data

If NULL, the functions try to load the data from the spotifyrecommendations package.

artist_distance_data

If NULL, the functions try to load the data from the spotifyrecommendations package.

local_genre_table_path

If NULL, the functions try to load the data from the spotifyrecommendations package.

artist_genre_table_path

If NULL, the functions try to load the data from the spotifyrecommendations package.

Value

A tibble of recommendations.


antaldaniel/spotify-recommendations documentation built on April 6, 2021, 6 a.m.