R: Retrieve ChemSpider ID
Retrieve ChemSpider ID
Description
Return Chemspider ID (CSID) for a search query, see http://www.chemspider.com/.
Usage
get_csid(query, token = NULL, first = TRUE, verbose = TRUE, ...)
Arguments
query |
charachter; search term.
|
token |
character; your security token.
|
first |
logical; If TRUE (default) return only first result.
|
verbose |
logical; should a verbose output be printed on the console?
|
... |
currently not used.
|
Value
if first = TRUE a character vector with ChemSpider IDs, otherwise a list.
Note
A security token is neeeded. Please register at RSC.
https://www.rsc.org/rsc-id/register
for a security token.
Please respect the Terms & conditions http://www.rsc.org/help-legal/legal/terms-conditions/.
Author(s)
Eduard Szoecs, eduardszoecs@gmail.com
See Also
cs_compinfo and cs_extcompinfo to
retrieve compound details from csid.
Examples
## Not run:
# Fails because no TOKEN is included
token <- '<YOUR-SECURITY-TOKEN>'
get_csid("Triclosan", token = token)[[1]]
# [1] "5363"
get_csid(c("Triclosan", "50-00-0"), token = token)
## End(Not run)
Results
|