Description Usage Arguments Details Value Author(s) See Also Examples
View source: R/RECORDS-get_recordId_image.R
This function is used to obtain a 250 x 250 pixel PNG image file of a ChemSpider record ID, e.g., after chemspiderapi::get_queryID_results()
.
1 | get_recordId_image(recordId, apikey, decode = FALSE, simplify = FALSE)
|
recordId |
A valid (integer) ChemSpider ID. |
apikey |
A 32-character string with a valid key for ChemSpider's API services. |
decode |
|
simplify |
|
Returns a numeric (double) array. To save the picture, see the vignette "Saving PNG Images of Chemicals".
A numeric array.
Raoul Wolf (https://github.com/RaoulWolf/)
https://developer.rsc.org/compounds-v1/apis/get/records/{recordId}/image
1 2 3 4 5 6 7 | ## Not run:
## Get the PNG image for caffeine
recordId <- 2424L
apikey <- "a_valid_ChemSpider_API_key"
get_recordId_image(recordId = recordId, apikey = apikey)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.