Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Get a 3D molecule plot with atoms or bonds colored according to property values
ResourceFunction["MoleculeValuePlot3D"][mol,property] returns a 3D molecule plot highlighted with colors corresponding to property. |
ColorFunction | Automatic | how to determine the coloring of atoms and bonds |
ColorFunctionScaling | True | whether to scale numeric arguments to ColorFunction |
"ExclusionFunction" | (False&) | function to determine which property values to exclude from the resulting plot |
Color each atom according to its partial charge:
In[1]:= |
|
Out[1]= |
|
Color atoms according to their hybridization:
In[2]:= |
|
Out[2]= |
|
Color bonds according to their bond type:
In[3]:= |
|
Out[3]= |
|
The atom and bond properties can be accessed via MoleculeValue and EntityProperties:
In[4]:= |
|
Out[4]= |
|
In[5]:= |
|
Out[5]= |
|
Label atoms by their phase at standard temperature and pressure:
In[6]:= |
|
Out[5]= |
|
Disable the plot legends using the PlotLegends option:
In[7]:= |
|
Out[7]= |
|
Specify an alternate color function for numeric data:
In[8]:= |
|
Out[8]= |
|
Specify an alternate color function for discrete data:
In[9]:= |
|
Out[9]= |
|
Pass options directly to the legend:
In[10]:= |
|
Out[10]= |
|
When some values are missing, the data is treated as discrete rather than numeric:
In[11]:= |
|
Out[11]= |
|
Use MissingQ to exclude missing values:
In[12]:= |
|
Out[12]= |
|
Label atoms by their chirality, using the "ExclusionFunction" option to make sure achiral atoms are not labeled:
In[13]:= |
|
Out[13]= |
|
This work is licensed under a Creative Commons Attribution 4.0 International License