PubChemR-classes {PubChemR} | R Documentation |
PubChemInstanceList
and PubChemInstance
Classes
Description
The PubChemInstanceList
object is a superclass returned by a request for compound(s) from
the PubChem Database, such as the output from get_compounds, get_assays, etc.
The PubChemInstance
object is another superclass for a PubChem instance, such as an assay, compound, substance, etc.
These instances are nested within the results
slot of a PubChemInstanceList
object. Similar to PubChemInstanceList
,
the PubChemInstance
also contains the same slots as described below. For more details, see instance.
Slots
results
:A list containing elements of each of the requested compounds, assays, substances, etc.
request_args
:A list containing the input arguments of a PubChem request.
success
:A logical value indicating whether the request was successfully completed (TRUE) or not (FALSE).
error
:A list detailing any errors encountered during the request, if applicable.
Note
There is no constructor function for the PubChemInstanceList
or PubChemInstance
classes. These objects are
constructed within related functions and returned as the output of PubChem requests.
There are several subclasses defined under the PubChemInstanceList
and PubChemInstance
superclasses. The PubChem API
returns request results in a list; however, each request may have a different list structure and/or items within the returned list.
Therefore, we have defined subclasses to make generic functions compatible with any PubChem request, such as assays, instances,
substances, etc. These subclasses may include PC_Compounds
, PC_Substance
, PC_Properties
, PubChemInstance_AIDs
,
PubChemInstance_SIDs
, PubChemInstance_CIDs
, PubChemInstance_Synonyms
, and PubChemInstance_Substances
.
Most of the defined subclasses have similar slots as described above. However, some classes may have additional slots not described here. Please refer to the contents of the returned object for more details.