R/pmc_listsets.R

Defines functions pmc_listsets

Documented in pmc_listsets

#' Retrieve the set structure of DataCite, useful for selective harvesting.
#' 
#' @import OAIHarvester
#' @inheritParams pmc_listmetadataformats
#' @examples \dontrun{
#' out <- pmc_listsets()
#' nrow(out); head(out)
#' out[nrow(out),]
#' }
#' @export
pmc_listsets <- function(url = "http://www.pubmedcentral.gov/oai/oai.cgi") 
{ 
	out <- oaih_list_sets(url, transform = FALSE)
	data.frame(
		setSpec = sapply(xpathApply(out, "//setSpec"), xmlValue),
		setName = sapply(xpathApply(out, "//setName"), xmlValue)
	)
}
ropensci/rpmc documentation built on May 18, 2022, 7:31 p.m.