get_formula_batch_queryId_results: Get results of a formula batch query from ChemSpider

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/FILTERING-get_formula_batch_queryId_results.R

Description

Get results of a formula batch query from ChemSpider after get_formula_batch_queryId_status() returns "Complete".

Usage

1
get_formula_batch_queryId_results(queryId, status, apikey, coerce = FALSE)

Arguments

queryId

A valid 36-character query ID, as returned by post_formula_batch().

status

A character string indicating the query status as returned by get_formula_batch_queryId_status().

apikey

A 32-character string with a valid key for ChemSpider's API services.

coerce

logical: should the list be coerced to a data.frame? Defaults to FALSE.

Details

Before running get_formula_batch_queryId_results(), make sure get_formula_batch_queryId_status() returns "Complete".

Value

Returns the (integer) ChemSpider IDs as list or data.frame.

Author(s)

Raoul Wolf (https://github.com/RaoulWolf/)

See Also

https://developer.rsc.org/compounds-v1/apis/get/filter/formula/batch/{queryId}/results

Examples

1
2
3
4
5
6
7
8
## Not run: 
## Obtain the result from a mass batch query
apikey <- "a valid 32-character ChemSpider apikey"
queryId <- "a valid 36-character ChemSpider queryId"
status <- get_formula_batch_queryId_status(queryId = queryId, apikey = apikey)
get_formula_batch_queryId_results(queryId = queryId, status = status, apikey = apikey)

## End(Not run)

NIVANorge/chemspiderapi documentation built on Jan. 10, 2021, 10:12 a.m.