Balkendiagramm ohne Achsen

Tabellen und Grafiken erstellen und anordnen


hell

Balkendiagramm ohne Achsen

Beitrag von hell »

Hi,

ich würde gerne folgende Grafik in Latex realisieren.

http://s14.directupload.net/file/d/2919 ... 2i_png.htm#

Ich versuche es schon seit einigen Tagen mit pgfplots die Balkendiagramme zu erstellen. Und diese in einer figure und minipage umgebung zusammen zu basteln.

Leider verzweifel ich an sogut wie allem.

\documentclass[a4paper, 11pt, oneside,landscape,]{scrbook}
\usepackage[latin1]{inputenc}
\usepackage[ngerman]{babel}

\usepackage{pgfplots}
\pgfplotsset{compat=1.3}
\usepackage{xcolor}

\begin{document}

%\subsection{Ergebnisse}
%\label{sec:rberg}

\begin{figure}[H]
	\centering
\begin{minipage}{0.2\textwidth}
				\centering\textbf{VA}
\end{minipage}
\begin{minipage}{0.3\textwidth}
				\centering\textbf{Rad}
\end{minipage}
\begin{minipage}{0.2\textwidth}
				\centering\textbf{HA}
\end{minipage}

\begin{minipage}{0.2\linewidth}

\begin{flushright}
		\begin{tikzpicture}
				\begin{axis}[
										xbar,
										enlargelimits=0.15,
										scale only axis,
										height=3cm, width=2cm,
										xmin=3,xmax=0,
										xtick={1,2,3},
										%xlabel={$F \left[kN\right]$},
										%                 y-Achse
										axis y line=right,
										ymin=0.9, 
										ymax=1.05,
										ytick={1},
										%ylabel={$U_{aus} \left[mV\right]$},
										]
						\addplot coordinates
							{(1,1) };
						\addplot coordinates
							{(2,1) };
						\addplot coordinates
							{(3,1) };
				\end{axis}
		\end{tikzpicture}
\end{flushright}
\end{minipage}
\begin{minipage}{0.4\linewidth}
\centering
\includegraphics[scale=0.5]{Bilder/03IstAnalyse/03.3Benchmark/raeder/testbild.jpg}
\end{minipage}

\begin{minipage}{0.2\linewidth}
\begin{flushleft}
		\begin{tikzpicture}
				\begin{axis}[
										xbar,
										enlargelimits=0.15,
										scale only axis,
										height=3cm, width=2cm,
										xmin=0,xmax=3,
										xtick={1,2,3},
										%xlabel={$F \left[kN\right]$},
										%                 y-Achse
										axis y line=left,
										ymin=0.9, 
										ymax=1.05,
										ytick={1},
										%ylabel={$U_{aus} \left[mV\right]$},
										]
						\addplot coordinates
							{(1,1) };
						\addplot coordinates
							{(2,1) };
						\addplot coordinates
							{(3,1) };
				\end{axis}
		\end{tikzpicture}
\end{flushleft}
\end{minipage}


	\caption{Benchmark Räder}
	\label{fig:benchmark}
\end{figure}

\end{document}

Jetzt habe ich folgende Fragen:

Wie bekomme ich die Achsen weg ?
Wie lass ich mir den max Wert der Balken (am Kopf des Balkens) anzeigen ?
Wie kann ich mir den Namen der Balken (am Fuß des Balkens) anzeigen lassen?


Ich bin für jeden Tipp dankbar.

Oder wenn jemand eine andere / bessere Idee kennt einfach schreiben.


VIELEN DANK

Hagbard Celine
Forum-Century
Forum-Century
Beiträge: 152
Registriert: Mi 23. Feb 2011, 22:13
Wohnort: Halle (Saale)

Beitrag von Hagbard Celine »

Hallo,
da ich mich selbst gerade ein wenig mit pgfplots beschäftige und das Problem interessant fand, habe ich mal ein wenig gesucht.
Die folgenden Optionen für die axis-Umgebung sollten zumindest 1,5 bis 2 deiner Fragen beantworten.
hide y axis,%	laesst die y-Achse verschwinden
hide x axis,%	laesst die x-Achse verschwinden
nodes near coords,%	erzeugt Beschriftung der Balken
nodes near coords align={horizontal},%	richtet Beschriftung am Balken aus
Allerdings weiß ich nicht, wie du die Maximalwerte in den Kopf der Balken bekommst.
Die Beschriftung am Fuß kannst du von Hand mit nodes (von TikZ) machen. Das ist nicht schön, sollte aber funktionieren. Dasselbe kannst du natürlich auch für die Maximalwerte tun, ist aber auch nicht gerade elegant.
Viele Grüße,
Jonas

hell

Beitrag von hell »

Hi Danke für den Tipp:


mittlerweile bin ich schon einwenig weiter:

\begin{figure}[H]
\begin{minipage}[m]{0.2\linewidth}
\begin{center}
\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/1.jpg}\\
\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/2.jpg}\\
\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/3.jpg}\\
%\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/4.jpg}\\
%\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/5.jpg}\\
\includegraphics[scale=0.45]{Bilder/03IstAnalyse/03.3Benchmark/raeder/6.jpg}
\end{center}\end{minipage}
\begin{minipage}[m]{0.4\linewidth}
\begin{flushright}
{\begin{tikzpicture}\begin{axis}
[xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.41,1) };
						\addplot coordinates{(1.9,1) };
						\addplot coordinates{(10.1,1) };
		\end{axis}\end{tikzpicture}}\\
		{\begin{tikzpicture}\begin{axis}
[xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.31,1) };
						\addplot coordinates{(1.73,1) };
						\addplot coordinates{(10.15,1) };
		\end{axis}\end{tikzpicture}}\\
{\begin{tikzpicture}\begin{axis}
[	xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.29,1)};
						\addplot coordinates{(1.74,1) };
						\addplot coordinates{(8.476,1) };
		\end{axis}\end{tikzpicture}}\\
%{\begin{tikzpicture}\begin{axis}
%[	xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
%						\addplot coordinates{(0.31,1)};
%						\addplot coordinates{(1.35,1) };
%						\addplot coordinates{(7.45,1) };
%		\end{axis}\end{tikzpicture}}\\
%		{\begin{tikzpicture}\begin{axis}
%[	xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
%						\addplot coordinates{(10.1,1)};
%						\addplot coordinates{(2,1) };
%						\addplot coordinates{(3,1) };
%		\end{axis}\end{tikzpicture}}\\
		{\begin{tikzpicture}\begin{axis}
[	xbar,enlargelimits=0.15,scale only axis,height=3cm, width=6cm,xmin=3,xmax=0,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(10.1,1)};
						\addplot coordinates{(2,1) };
						\addplot coordinates{(3,1) };
		\end{axis}\end{tikzpicture}}
\end{flushright}
\end{minipage}
\begin{minipage}[m]{0.4\linewidth}
\begin{flushleft}
{\begin{tikzpicture}\begin{axis}
		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.45,1)};
						\addplot coordinates{(2.4,1) };
						\addplot coordinates{(10.24,1) };
		\end{axis}\end{tikzpicture}}\\
{\begin{tikzpicture}\begin{axis}
		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.37,1)};
						\addplot coordinates{(2.01) };
						\addplot coordinates{(10.7,1) };
		\end{axis}\end{tikzpicture}}\\
{\begin{tikzpicture}\begin{axis}
		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(0.39,1)};
						\addplot coordinates{(1.67,1) };
						\addplot coordinates{(8.771,1) };
		\end{axis}\end{tikzpicture}}\\
{\begin{tikzpicture}\begin{axis}
%		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
%						\addplot coordinates{(0.33,1)};
%						\addplot coordinates{(1.67,1) };
%						\addplot coordinates{(8.417,1) };
%		\end{axis}\end{tikzpicture}}\\
%%		{\begin{tikzpicture}\begin{axis}
%%		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
%%						\addplot coordinates{(1,1)};
%%						\addplot coordinates{(2,1) };
%%						\addplot coordinates{(3,1) };
%%		\end{axis}\end{tikzpicture}}\\
		{\begin{tikzpicture}\begin{axis}
		[	xbar,enlargelimits=0.15,scale only axis,	height=3cm, width=6cm,xmin=0,xmax=3,xtick={1,2,3},axis y line=none,axis x line=none,ymin=0.9,ymax=1.09,ytick={1},bar width=25pt,]
						\addplot coordinates{(1,1)};
						\addplot coordinates{(2,1) };
						\addplot coordinates{(3,1) };
		\end{axis}\end{tikzpicture}}
\end{flushleft}
\end{minipage}
\end{figure}


Leider fehlt mir die Zeit um da weiter zur arbeiten.

:) aber kommt Zeit kommt Lösung

Antworten