'How can i chose the Atom for a branch in Chemfig?

\documentclass[11pt,a4paper]{report}
\usepackage{chemfig}
\usepackage{chemmacros}
\chemsetup{modules={all}}
\chemsetup{formula = mhchem}

\begin{document}

\chemname[2ex]{\chemfig{[:-150]*6(-(-OH)=(-OH)-=-(-([7]-OH)-[1]-NH([1]-CH_3))=)}}{Epinephrin}
\end{document}

enter image description here

Right now the Image looks like the above. I would like the Methyl-group (CH3) to branch off at the Nitrogen Atom (N).

I hope somebody can help me. Thanks in advance! :)



Solution 1:[1]

You could change the angle:

\documentclass[11pt,a4paper]{report}
\usepackage{chemfig}
\usepackage{chemmacros}
\chemsetup{modules={all}}
\chemsetup{formula = mhchem}

\begin{document}

\chemname[2ex]{\chemfig{[:-150]*6(-(-OH)=(-OH)-=-(-([7]-OH)-[1]-NH([2]-CH_3))=)}}{Epinephrin}
\end{document}

enter image description here

Or if you like the 45 degree angle, you could specify which atom should be the bonding partner:

\documentclass[11pt,a4paper]{report}
\usepackage{chemfig}
\usepackage{chemmacros}
\chemsetup{modules={all}}
\chemsetup{formula = mhchem}

\begin{document}

\chemname[2ex]{\chemfig{[:-150]*6(-(-OH)=(-OH)-=-(-([7]-OH)-[1]-NH([1,,1,]-CH_3))=)}}{Epinephrin}
\end{document}

enter image description here

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1