2

Why does this not produce y tick labels in fixed number format? (pgfplots version 1.9 produces y tick labels in scientific format)

\documentclass[12pt]{article} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis}[y tick label style={/pgf/number format/fixed}] \addplot{cos(x)/12.0}; \end{axis} \end{tikzpicture} \end{document} 
0

1 Answer 1

2

Adding a zerofill={true} will fix this:

Sample output

\documentclass[12pt]{article} \usepackage{pgfplots} \pgfplotsset{compat=1.11} \begin{document} \begin{tikzpicture} \begin{axis}[y tick label style={/pgf/number format/fixed, /pgf/number format/fixed zerofill={true}}] \addplot{cos(x)/12.0}; \end{axis} \end{tikzpicture} \end{document} 
1
  • Thank you, but I'd like the numbers to come out as 0.0830 instead of $0.0830 \times 10^{-2}$. I didn't know how to force that. (My actual graph is obviously different from the above one.) I've since found out that scaled y ticks=false does what I want, but I'll accept your answer regardless. Commented Sep 10, 2014 at 0:04

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.