Returns a list of dictionaries with information corresponding to each collection stored in NeuroVault. Results can be filtered by specifying the name, DOI or owner of the collection.

nv_collection(
  id = NULL,
  doi = NULL,
  owner = NULL,
  name = NULL,
  verbose = TRUE,
  secure = TRUE,
  max_count = Inf,
  ...
)

Arguments

id

id of the collection

doi

Digital Object Identifier (DOI) for the project or collection

owner

owner of the collection

name

name of the collection

verbose

print diagnostic messages

secure

passed to nv_base_url for https

max_count

Maximum count of records to call, the number of records may be larger than this based on how the limits are set for API calls

...

additional options to pass to GET

Value

List of the result of the GET call and the content

Note

See https://neurovault.org/api-docs

Examples

res = nv_collection(doi = "10.1016/j.neurobiolaging.2012.11.002")
#> GET command is:
#> Response [https://neurovault.org/api/collections/?DOI=10.1016%2Fj.neurobiolaging.2012.11.002] #> Date: 2020-03-18 16:22 #> Status: 200 #> Content-Type: application/json; charset=utf-8 #> Size: 3.47 kB #>
res = nv_collection(name = "21 pain studies (NIDM-Results)")
#> GET command is:
#> Response [https://neurovault.org/api/collections/?name=21%20pain%20studies%20%28NIDM-Results%29] #> Date: 2020-03-18 16:22 #> Status: 200 #> Content-Type: application/json; charset=utf-8 #> Size: 2.97 kB #>
res = nv_collection(id = 77)
#> GET command is:
#> Response [https://neurovault.org/api/collections/77/] #> Date: 2020-03-18 16:22 #> Status: 200 #> Content-Type: application/json; charset=utf-8 #> Size: 3.42 kB #>
res = nv_collection(id = 77, doi = "10.1016/j.neurobiolaging.2012.11.002")
#> Warning: ID and doi/owner/name specified, ID will be used, others ignored
#> GET command is:
#> Response [https://neurovault.org/api/collections/77/] #> Date: 2020-03-18 16:22 #> Status: 200 #> Content-Type: application/json; charset=utf-8 #> Size: 3.42 kB #>
res = nv_collection(max_count = 100)
#> No doi/owner/name/id have been specified - all collections!
#> GET command is:
#> Response [https://neurovault.org/api/collections/] #> Date: 2020-03-18 16:22 #> Status: 200 #> Content-Type: application/json; charset=utf-8 #> Size: 300 kB #>
#> Multiple pages must be called - more results than 1 call