# Adding text to plot that is a crystal direction

1 view (last 30 days)
Benjamin Cowen on 10 Jan 2017
Commented: Walter Roberson on 11 Jan 2017
Hey, so I want to add text to a plot that is a crystal direction. Sounds easy enough, right?
It's easy to do [110], but what if I want to do [-110]? If you are familiar with crystallography, you know that the negative sign should be above the 1. How can I do this?
##### 1 CommentShowHide None
Star Strider on 10 Jan 2017
I doubt many here are familiar with crystallography. (I’m not.) Do you have an open-source (not behind a paywall) reference so we can possibly understand what you’re doing?

Walter Roberson on 10 Jan 2017
text(xpos, ypos, '$\stackrel{-}{1} 1 0$','interpreter','latex')
or '$\bar{1} 1 0$' or '$\overline{1} 1 0$'
The shortest line is with \bar, then \stackrel, and \overline is longest.
The gap between the line and the digit appears to be smallest with \bar, then \overline, and largest with \stackrel
I find the \stackrel version easiest to read.
Walter Roberson on 11 Jan 2017
Put \$ pair around the text perhaps?