MoleculeGraph

MoleculeGraph[mol]

returns a graph constructed from the molecule mol.

Examples

Basic Examples  (2)

Create a graph from a molecule:

In[1]:=
Click for copyable input
Out[1]=

The returned graph is undirected:

In[2]:=
Click for copyable input
Out[2]=

Query for the atom and bond properties:

In[3]:=
Click for copyable input
Out[3]=
In[4]:=
Click for copyable input
Out[4]=

Create a graph from only the heavy atoms:

In[1]:=
Click for copyable input
Out[1]=
Introduced in 2019
(12.0)