In SMILES I would think that $\ce{XeF6}$ would be F[Xe](F)(F)(F)(F)F
or F[Xe](F)(F)(F)(F)(F)
. A quick Wikipedia search showed that the first result is the correct SMILES string. However, rdkit isn't able to convert either SMILES strings into a structure.
Here is my code:
from IPython.display import SVG
from rdkit import Chem
from rdkit.Chem import rdDepictor
from rdkit.Chem.Draw import rdMolDraw2D
# Create mol object from smiles string
# mol = Chem.MolFromSmiles('[B](C7OC7)(CCC3CCCC31N2CN([P]5CCCC8C5)C2(CO8)CC1)(C6CCC6)')
# The above molecule was me learning SMILES, below is the Xenon Hexafluoride string
mol = Chem.MolFromSmiles('F[Xe](F)(F)(F)(F)')
molSize=(900,300)
mc = Chem.Mol(mol.ToBinary())
if not mc.GetNumConformers():
#Compute 2D coordinates
rdDepictor.Compute2DCoords(mc)
# init the drawer with the size
drawer = rdMolDraw2D.MolDraw2DSVG(molSize[0],molSize[1])
#draw the molcule
drawer.DrawMolecule(mc)
drawer.FinishDrawing()
# get the SVG string
svg = drawer.GetDrawingText()
# fix the svg string and display it
display(SVG(svg.replace('svg:','')))