get_queryId_results_sdf: Get a gzipped SDF file for a ChemSpider query

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

View source: R/FILTERING-get_queryId_results_sdf.R

Description

This function is used to download a single .sdf file from ChemSpider after get_queryId_status() returns "Complete".

Usage

1
2
3
4
5
6
7
get_queryId_results_sdf(
  queryId,
  status,
  apikey,
  decode = TRUE,
  simplify = FALSE
)

Arguments

queryId

A valid 36-character ChemSpider queryId.

status

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

apikey

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

decode

logical: should the base64-encoded gzipped file be decoded? Defaults to TRUE.

simplify

logical: should the results be simplified to a vector? Defaults to FALSE.

Details

Call this function after get_queryId_status() returns "Complete".

Value

Returns a (base64-encoded) character vector

Author(s)

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

See Also

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

Examples

1
2
3
4
5
6
7
## Not run: 
## Get a gzipped .sdf file
queryId <- "a valid 36-character ChemSpider apikey"
apikey <- "a valid 32-character ChemSpider apikey"
get_queryId_results_sdf(queryId = queryId, apikey = apikey)

## End(Not run)

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