Base function to search PLoS Journals

Usage

searchplos(terms = NA, fields = NA, toquery = NA, start = 0, limit = 1000, url = "http://api.plos.org/search",
  key = getOption("PlosApiKey", stop("need an API key for PLoS Journals")), ...,
      curl = getCurlHandle())

Arguments

terms
search terms (character)
fields
fields to return from search (character) [e.g., 'id,title'], any combination of search fields [type 'data(plosfields)', then 'plosfields']
toquery
list specific fields to query (if NA, all queried)
start
record to start at (used in combination with limit when you need to cycle through more results than the max allowed=1000)
limit
number of results to return (integer)
url
the PLoS API url for the function (should be left to default)
key
your PLoS API key, either enter, or loads from .Rprofile
...
optional additional curl options (debugging tools mostly)
curl
If using in a loop, call getCurlHandle() first and pass the returned value in here (avoids unnecessary footprint)

Value

Number of search results (vis = FALSE), or number of search in a table and a histogram of results (vis = TRUE).

Description

Base function to search PLoS Journals

Examples

## Not run: # searchplos('ecology', 'id', limit = 2)# searchplos('ecology', 'id,publication_date', limit = 2)# searchplos('ecology', 'id', limit = 100)# searchplos('ecology', 'id,title', limit = 2)# searchplos(terms="*:*", fields='id', toquery='doc_type:full', start=0, limit=250)# searchplos(terms="*:*", fields='id', toquery='cross_published_journal_key:PLoSONE', start=0, limit=250)# searchplos(terms="*:*", fields='id',# toquery=list('cross_published_journal_key:PLoSONE', 'doc_type:full'),# start=0, limit=250)# ## End(Not run)