Skip to content

Instantly share code, notes, and snippets.

Created October 9, 2014 20:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/1ee5da808052e8b147ff to your computer and use it in GitHub Desktop.
Save anonymous/1ee5da808052e8b147ff to your computer and use it in GitHub Desktop.
\documentclass{article}
\usepackage{tikz}
\usepackage{pgfplots}
\begin{document}
\begin{tikzpicture}
\pgfplotsset{tick style={very thin,gray,font=\fontnotesize}}
\begin{axis}[xmin=0,ymin=0,xmax=6,ymax=6,grid=major,ytick={0,...,6}]
\addplot[
black,
thick,
mark=*,
mark options={fill=white},
visualization depends on=\thisrow{alignment} \as \alignment,
nodes near coords, % Place nodes near each coordinate
point meta=explicit symbolic, % The meta data used in the nodes is not explicitly provided and not numeric
every node near coord/.style={anchor=\alignment} % Align each coordinate at the anchor 40 degrees clockwise from the right edge
] table [% Provide data as a table
meta index=2 % the meta data is found in the third column
] {
x y label alignment
};
\end{axis}
\end{tikzpicture}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment