Überarbeitungsverlauf[Zurück]
Klicke auf Einblenden/Ausblenden von Überarbeitungen 4

20 Aug '15, 11:57

esdd's gravatar image

esdd
17.8k304257

Wie man die Achsenbeschriftung Ticklabel beliebig verschieben kann, hat @saputello schon gezeigt. Wenn man aber automatisch eine bessere gute Positionierung des Achsenlabels und der Label und Ticklabel möchte, braucht man nur die `pgfplots` Version 1.8 oder neuer mit einer entsprechenden Angabe für `compat`: \pgfplotsset{compat=1.12}% derzeit aktuelle Version oder \pgfplotsset{compat=newest}% wenn mindestens Version 1.8 installiert ist ![alt text][1] Code: \documentclass{standalone} \usepackage{pgfplots} \pgfplotsset{% %compat=1.12 compat=newest% auf sharelatex ist noch nicht die 1.12 } \begin{document} \begin{tikzpicture} \begin{axis}[ height=7cm, width=\textwidth, ybar, xmin = 1984, xmax = 2015, ymin = 0, ymax = 2, xtick={1985,...,2015}, xtick pos=left, x tick label style={rotate=90, anchor=east, /pgf/number format/1000 sep=}, ylabel={Number of failure}, ytick={0,...,2} ] \addplot coordinates { (1985, 0) (1986, 0) (1987, 0) (1988, 0) (1989, 0) (1990, 0) (1991, 0) (1992, 0) (1993, 0) (1994, 0) (1995, 0) (1996, 0) (1997, 0) (1998, 0) (1999, 0) (2000, 0) (2001, 0) (2002, 0) (2003, 0) (2004, 0) (2005, 0) (2006, 0) (2007, 0) (2008, 0) (2009, 0) (2010, 0) (2011, 0) (2012, 0) (2013, 0) (2014, 0) (2015, 0) (2012, 1) }; \end{axis} \end{tikzpicture} \end{document} [1]: http://texwelt.de/wissen/upfiles/tw_compat_1.png
Klicke auf Einblenden/Ausblenden von Überarbeitungen 3

20 Aug '15, 11:54

esdd's gravatar image

esdd
17.8k304257

Wie man das Label die Achsenbeschriftung beliebig verschieben kann, hat @saputello schon gezeigt. Wenn man aber automatisch eine bessere Positionierung der Label und Ticklabel möchte, braucht man nur die `pgfplots` Version 1.8 oder neuer mit einer entsprechenden Angabe für `compat`: \pgfplotsset{compat=1.12}% derzeit aktuelle Version oder \pgfplotsset{compat=newest}% wenn mindestens Version 1.8 installiert ist ![alt text][1] Code: \documentclass{standalone} \usepackage{pgfplots} \pgfplotsset{% %compat=1.12 compat=newest% auf sharelatex ist noch nicht die 1.12 } \begin{document} \begin{tikzpicture} \begin{axis}[ height=7cm, width=\textwidth, ybar, xmin = 1984, xmax = 2015, ymin = 0, ymax = 2, xtick={1985,...,2015}, xtick pos=left, x tick label style={rotate=90, anchor=east, /pgf/number format/1000 sep=}, ylabel={Number of failure}, ytick={0,...,2} ] \addplot coordinates { (1985, 0) (1986, 0) (1987, 0) (1988, 0) (1989, 0) (1990, 0) (1991, 0) (1992, 0) (1993, 0) (1994, 0) (1995, 0) (1996, 0) (1997, 0) (1998, 0) (1999, 0) (2000, 0) (2001, 0) (2002, 0) (2003, 0) (2004, 0) (2005, 0) (2006, 0) (2007, 0) (2008, 0) (2009, 0) (2010, 0) (2011, 0) (2012, 0) (2013, 0) (2014, 0) (2015, 0) (2012, 1) }; \end{axis} \end{tikzpicture} \end{document} [1]: http://texwelt.de/wissen/upfiles/tw_compat_1.png
Klicke auf Einblenden/Ausblenden von Überarbeitungen 2

20 Aug '15, 11:41

esdd's gravatar image

esdd
17.8k304257

Klicke auf Einblenden/Ausblenden von Überarbeitungen 1

20 Aug '15, 11:41

esdd's gravatar image

esdd
17.8k304257

Willkommen, erstes Mal hier? Schau mal unter FAQ!

×