update_scrobbles: update_scrobbles

View source: R/get_pages_api.R

update_scrobblesR Documentation

update_scrobbles

Description

Companion function to 'download_scrobbles'. Only downloads the scrobbles that have been stored since you ran 'download_scrobbles'.

Usage

update_scrobbles(
  data,
  timestamp_column,
  username = get_lastfm_credentials("username"),
  api_key = get_lastfm_credentials("key"),
  max_per_page = 1000
)

Arguments

data

A dataframe outputted by 'download_scrobbles'

timestamp_column

The 'date_unix' column in your dataframe

username

Last.fm API username

api_key

Last.fm API key

max_per_page

Controls the maximum number of songs on each page of the API. A lower number here will lead to a higher number total pages. Defaults to 1000. Mainly useful for testing. description

Value

A dataframe

Examples

## Not run: 
mydat <- download_scrobbles(username = "your_username", api_key = "your_api_key")
update_dat <- update_scrobbles(mydat,
    "date_unix",
    username = "your_username",
    api_key = "your_api_key")

## End(Not run)

condwanaland/scrobbler documentation built on Oct. 25, 2023, 2:55 p.m.