Learn R Programming

PubChemR (version 2.1.3)

AIDs-SIDs-CIDs: Assay, Compound, and Substance Identifiers

Description

These functions are used to retrieve identification information for assays, substances, and compounds from the PubChem database.

Usage

AIDs(object, ...)

CIDs(object, ...)

SIDs(object, ...)

# S3 method for PubChemInstance_AIDs AIDs(object, .to.data.frame = TRUE, ...)

# S3 method for PubChemInstance_CIDs CIDs(object, .to.data.frame = TRUE, ...)

# S3 method for PubChemInstance_SIDs SIDs(object, .to.data.frame = TRUE, ...)

Arguments

object

An object returned from a PubChem request, typically generated by functions such as get_cids, get_aids, and get_sids.

...

Additional arguments passed to other methods. Currently, these arguments have no effect.

.to.data.frame

a logical. If TRUE, returned object will be forced to be converted into a data.frame (or tibble). If failed to convert into a data.frame, a list will be returned with a warning. Be careful for complicated lists (i.e., many elements nested within each other) since it may be time consuming to convert such lists into a data frame.

Examples

Run this code
# Retrieve Assay IDs
aids <- get_aids(identifier = c("aspirin", "caffeine"), namespace = "name")
AIDs(aids)

# Compound IDs
cids <- get_cids(identifier = c("aspirin", "caffein"), namespace = "name")
CIDs(cids)

# Substance IDs
sids <- get_sids(identifier = c("aspirin", "caffein"), namespace = "name")
SIDs(sids)

Run the code above in your browser using DataLab