Learn R Programming

rcrossref (version 0.3.0)

cr_prefixes: Search CrossRef prefixes

Description

Search CrossRef prefixes

Usage

cr_prefixes(prefixes, query = NULL, filter = NULL, offset = NULL,
  limit = NULL, sample = NULL, sort = NULL, order = NULL,
  facet = FALSE, works = FALSE, .progress = "none", ...)

Arguments

prefixes
(character) Publisher prefixes, one or more in a vector or list. Required.
query
Query terms
filter
Filter options. See details.
offset
Number of record to start at, from 1 to infinity.
limit
Number of results to return in the query. Not relavant when searching with specific dois. Default: 20. Max: 1000
sample
(integer) Number of random results to return. when you use the sample parameter, the rows and offset parameters are ignored.
sort
(character) Field to sort on, one of score, relevance, updated, deposited, indexed, or published.
order
(character) Sort order, one of 'asc' or 'desc'
facet
(logical) Include facet results. Facet data not yet included in output.
works
(logical) If TRUE, works returned as well, if not then not.
.progress
Show a plyr-style progress bar? Options are "none", "text", "tk", "win, and "time". See create_progress_bar for details of each.
...
Named parameters passed on to GET

Details

BEWARE: The API will only work for CrossRef DOIs.

Note that any one publisher can have more than one DOI. If you want to search on all DOIs for a publisher, pass in all DOIs, or see cr_members, and pass in the member_ids parameter.

Notes from CrossRef (quoting them):

The prefix of a CrossRef DOI does NOT indicate who currently owns the DOI. It only reflects who originally registered the DOI. CrossRef metadata has an owner_prefix element that records the current owner of the CrossRef DOI in question.

CrossRef also has member IDs for depositing organisations. A single member may control multiple owner prefixes, which in turn may control a number of DOIs. When looking at works published by a certain organisaton, member IDs and the member routes should be used.

References

https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md

Examples

Run this code
cr_prefixes(prefixes="10.1016")
cr_prefixes(prefixes="10.1016", works=TRUE)
cr_prefixes(prefixes=c('10.1016','10.1371','10.1023','10.4176','10.1093'))
cr_prefixes(prefixes=c('10.1016','10.1371'), works=TRUE)
cr_works(prefixes="10.1016", filter=c(has_full_text=TRUE), limit=5)
cr_works(prefixes="10.1016", query='ecology', limit=4)
cr_works(prefixes="10.1016", query='ecology', limit=4)

# facets
## if works is FALSE, then facets ignored
cr_prefixes(prefixes="10.1016", works=FALSE, facet=TRUE)
## get facets back
cr_prefixes(prefixes="10.1016", works=TRUE, facet=TRUE)
cr_prefixes(prefixes=c('10.1016','10.1371'), works=TRUE, facet=TRUE)

Run the code above in your browser using DataLab