Learn R Programming

openalexR (version 2.0.0)

topics2df: Convert OpenAlex collection of topics' records from list format to data frame

Description

It converts collection of topics' records gathered from the OpenAlex database. The function converts a list of topics' records obtained using oa_request into a data frame/tibble.

Usage

topics2df(
  data,
  verbose = TRUE,
  pb = if (verbose) oa_progress(length(data)) else NULL
)

Value

a data.frame.

For more extensive information about OpenAlex API, please visit: <https://docs.openalex.org>

Arguments

data

List. Output of oa_request.

verbose

Logical. If TRUE, print information about the dataframe conversion process. Defaults to TRUE.

pb

Progress bar object. If verbose, computed from `oa_progress`. NULL otherwise.

Examples

Run this code
if (FALSE) {

# Query to search information about all Italian educational institutions


res <- oa_query(
  entity = "topics",
  display_name.search = "electrodynamics",
  output = "list"
)

df <- oa2df(res, entity = "topics")

df
}

Run the code above in your browser using DataLab