getRankSnapshot: Retrieve a cross section of rank data.

View source: R/getRanks.R

getRankSnapshotR Documentation

Retrieve a cross section of rank data.

Description

getRankSnapshot requests data for the top ranked apps for for a specific hour from the appFigures web API.

Usage

getRankSnapshot(timestamp, category = 25204, subcategory = c("free",
  "paid", "topgrossing"), country = "US", count = 400, start = 1,
  tz = "utc", curlHandle, verbose = FALSE, orgJSON = FALSE,
  async = FALSE)

Arguments

timestamp

Either the string "current" (default) or a string with the format: "yyyy-MM-ddTHH". Only the last 24 hours are available.

category

Numeric. The numeric category of the requested snapshot. Defaults to 25204 (ios top overall).

subcategory

Character. The sub-category of the requested#' snapshot. Defaults to "free".

country

Chatacter. A country iso2 abbreviation. Defaults to 'US'.

count

Numeric. The total number of the ranks to return. See Details.

start

Smallest rank value the request returns. See Details.

curlHandle

Provide an instance of the CURLHandle-class from the RCurl package. The default will create a curl handle specific to the function call.

verbose

Logical. Should details of the web request print to the console? Defaults to FALSE.

orgJSON

Logical. Should the JSON string be returned without being converted to R objects? Defaults to FALSE.

async

Logical. Should the given time-stamps run concurrently? Defaults to FALSE. See Details.

Details

The use of the start argument differs from the official API documentation. A value such as start = 15 will return a list of products starting with a rank value of 15. If start = 15 and count = 10, then products data for apps ranked from 15 - 24 will be returned.

As of now, multiple time-stamp requests are the only input variable that can run concurrently.

Value

A data frame containing product and category data for a cross section of top ranked apps.

See Also

Official documentation: http://docs.appfigures.com/api/reference/v2/ranks.


appfigures/afapi documentation built on Nov. 13, 2022, 9:27 a.m.