btQuery-methods: btQuery

Description Usage Arguments Value Examples

Description

Retrieve results from the query endpoint of BioThings APIs

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
btQuery(biothings, q, ..., fetch_all = FALSE, scopes, return.as = "records")

## S4 method for signature 'BioThingsClient'
btQuery(biothings, q, ..., fetch_all = FALSE,
  scopes, return.as = "records")

## S4 method for signature 'missing'
btQuery(biothings, q, ..., fetch_all = FALSE, scopes,
  return.as = "records")

## S4 method for signature 'character'
btQuery(biothings, q, ..., fetch_all = FALSE, scopes,
  return.as = "records")

Arguments

biothings

An S4 class BioThings object

q

A query string

...

Any parameters to pass to API

fetch_all

This returns a list of _all_ results for a query, regardless of return.as. See the API documentation.

scopes

One or more fields (separated by comma) as the search "scopes"

return.as

Type of return value

Value

Returns the API result as the provided return.as type

Examples

1
2
3
btQuery("gene", q = "NM_013993")
gene_client <- BioThingsClient("gene")
btQuery(gene_client, "NM_013993")

biothings/biothings_client.R documentation built on Jan. 12, 2018, 7:56 a.m.