about creating bar charts using TeX/LaTeX/etc.

learn more… | top users | synonyms

1
vote
0answers
32 views

How to do 3d barcharts in latex using tikz?

I wanted to do a barchart for annual report. I have made it in excel There are so many problems of using this in latex as it is since I dont want any backgroud for this. In the sense that it has to ...
1
vote
1answer
31 views

Changing commas and dot on bar graph

Here's what I have right now: Is there a way to change commas for dots and vice versa? This table was made using the answer from this question, so it's basically the same thing. This isnt't an ...
0
votes
0answers
42 views

How to make a grouped bar plot with different sized bars?

I want plots with grouped bars, two y axes and bars of different size shown in the Pictures below: What i got so far: \documentclass[x11names]{article} \usepackage{pgfplots} \begin{...
7
votes
1answer
152 views

How can I get a stacked bar with single values and sum on the side

Based on this question I was able to put partial and total values on my bar plot. My bars have some really small values though and it is impossible to fit the numbers in some ranges. I would like to ...
1
vote
0answers
38 views

Add spacing between every second bar tikzpicture

So I've created this chart below from a .csv file with the code at the bottom. However I would like to add some spacing between the 2&3 bars and 4&5 bars. Is this possible or do I need to ...
3
votes
1answer
51 views

Missing xtick labels from table in bar plot whenever y value is nan

Given a picture like that: \documentclass[12pt]{article} \usepackage{pgfplots} \usepgfplotslibrary{external} \tikzexternalize \pgfplotsset{compat=newest} \pgfplotstableread[col sep=comma]{ netname,...
3
votes
1answer
52 views

Assigning xlabels to symbolic x coords

I am using the below code to generate the shown bar graph. However, I cant find anything with which I can label each of the individual bars for both sets of my data. i.e say the bar marked 0.67 I want ...
1
vote
1answer
40 views

bar graph not showing the first bar with pgfplot

I have the following table in a .txt file Group Real Imag Cable VSC P-mode VSC Vdc-mode A -1.2739095e+02 -3.3612954e+02 4.9822998e-01 4.9309456e-01 8.6754595e-03 B -3....
5
votes
2answers
209 views

How to customize Tikz Gantt chart

I am trying to find a way to obtain the following using tikz (actually using pgfgantt): The code I have so far is: \documentclass[tikz]{standalone} \usepackage{pgfgantt} \begin{document} \begin{...
2
votes
1answer
55 views

Density and overlapping in tikz chart

I got the following code right now for my chart: \begin{figure} \setlength{\fboxrule}{0pt} \fbox{ \vspace*{-100pt} \begin{tikzpicture}[every node/.style={font=\scalefont{1}}] \centering \...
1
vote
0answers
66 views

Drawing Bar charts with Std.deviation and Confd.level with PGFPlots

I want to draw a bar chart where on each bar it shows the standard deviation(and also confidence level). I tried using following solution but I get the "dimension too large" error. Basically I have ...
0
votes
1answer
89 views

How to display the y-values of each bar in pgfplots bar chart above the bar?

I am using code from this thread. link: Making one bar in a bar-graph stand out pgfplots Everything is working fine but I want to display the y-values of each bar in pgfplots bar chart above the bar. ...
0
votes
0answers
25 views

Bar chart in Latex for numbers occurency

I have the following set of data (it is only a part, in reality is way longer than this): 200 200 0 0 4 4 4 8 20 8 20 and I'd like to build a bar plot in Latex where the X-axis reports all the ...
6
votes
1answer
115 views

pgfplots: change order of barplots

When one has more then one barplot in one pgfplots axis like in the following example then the red plot at the top of the code ends up as the bottom bar of the plot. I do find this confusing -- ...
2
votes
1answer
65 views

Positioning tikzpicture and determining range for axis

In another question I got great help creating this picture: Actually it looks how it should but there are two further things I would like to clarify: Firstly, I get this warning: Axis range for ...
1
vote
3answers
222 views

How to do a chart with stacked bars, lines and “sections”

The problem I need a chart like this (this was made in Libreoffice + some gimp): Its caracteristics are bassically: Some stacked bars (if it is a stacked area, better) with its Y axis at the ...
0
votes
1answer
82 views

How to unstack grouped bars in pgfplots bar-charts

I am sure this is quite a trivial problem, but I cannot seem to figure it out. I have a bar-chart with preferably three groups of four bars. The thing is, using the MWE below, the four bars per group ...
3
votes
1answer
304 views

Basic Bar Plot with long text legend, horizontal guides and percentage values

I am new to pgfplots and actually I want to create something pretty basic. Yesterday, I started modifying my chart with the help of the pgfplot manual and the help of Google but unfortunately, I ...
4
votes
1answer
132 views

Misplaced nodes near coords in stacked ybar plot

I have this stacked ybar plot and having trouble to proper align the nodes near the coords. It works fine on all bar but the one with offset 65. I already tried \ifnum as @Jake suggested here: How can ...
3
votes
1answer
133 views

pgfplots legend with two ordinates (lines and bar chart)

In the legend, I would like to have a line for the red and orange lines (as it is the case), and ybar legend style for the rest. I just can't figure out the easiest/best/any way to do it. MWE: \...
6
votes
1answer
334 views

colour each x co-ordinate with a different colour in a bar plot in pgfplot

I want to cycle colours for each x co-ordinate in a bar plot. Is it possible? For instance, in this example I want each metric to appear in a different colour. This question Colors and legend in ...
4
votes
1answer
112 views

How to evaluate the height of a ybar to change color of label accordingly

Problem I want to change the color of a node near coords label depending on the height of the bar it lies on. That is, if the label is outside the bar I want to put a color that is different from the ...
0
votes
1answer
40 views

Changing color on advanced bar chart (pgfplotstable)

I have made a stacked and clustered diagram, based on this brilliant answer: http://tex.stackexchange.com/a/55559/93892. However, I would like to change the colors of the bars. The most important ...
0
votes
1answer
92 views

how to insert number inside the stacked bar?

I tried stacked graph but i need inside bar to set alphanumberic like p1,p2,p3. My MWE \documentclass{article} \usepackage{pgfplots} % to print charts %\pgfplotsset{compat=1.8} %\...
1
vote
2answers
89 views

How can stacked bars be plotted?

I try to create a stacked bar plot with given values with the pgfplots package, but it shows some errors. Can anyone correct the given errors? \documentclass[border=10pt]{standalone} \usepackage{...
1
vote
0answers
93 views

From a bar chart with multiple values per ticks to a stacked bar chart

I succeeded to generate a bar chart from a table which provides multiple values per ticks. The code is given in the following code: \documentclass{standalone} \usepackage{pgfplots} \usepackage{...
8
votes
1answer
161 views

Two plots, change bar plot reference system only

TL;DR How can I make a horizontal bar plot with the origin on the right? I wanted to combine several plots in a unique figure. I have a custom scatter plot, and I want to overlay it on top of a bar ...
1
vote
0answers
24 views

Insert space after each second bar

I have a bar plot which shows 7 bars for one xtick. I want to group two bars by inserting some space after each second bar. I tried to use xshift in the \addplot command, but the color of the bar ...
2
votes
2answers
121 views

pgfplots: annotate each bar in a group with custom values

how can I add custom annotations to each bar in a grouped bar chart? I know how to display the values from the the bars (with every node near...), but the values I need to display, above or below the ...
2
votes
1answer
128 views

Pgfplots: vertical bar char prints only labels at one bar

I want to create a vertical bar charts with two bars in it. At the x-axis the bars shall be labeled with A and B. The label A is printed although it is not exactly properly positioned, but the label B ...
4
votes
1answer
92 views

Add areas in background of histogram

I would like that my histogram has areas in background (with name), in order to compare the value of each bar with some intervals. This is the result that I would like to reach: And this what I ...
2
votes
1answer
191 views

Symbolic Labels in pgfplots Bar Chart

In the following code, why do I have to type the x-axis labels explicitly in the axis options and not just use the labels from the coordinates data? Is there a way to just use the data from the ...
0
votes
1answer
173 views

How to draw multiple bar charts each one with multiple different series

I want to draw a chart which includes multiples bar chart, and each one include different series. This is what I ´ve already have. In this case Alg 1, Alg3,..., Alg 7 would be my multiple bar charts, ...
1
vote
0answers
129 views

Two axis y discontinuity=parallel

I am trying to complete this bar graph with two y discontinuities since my third coordinates are too far from the remaining two coordinates. Below is a MWE can anyone provide me with an approach to ...
4
votes
1answer
139 views

Barchart with pgfplot in beamer slides

I am trying to use a code in my beamer presentation for a barchart that I had previously used for an article type document. I am using TeXstudio as the editor. Everytime I try to compile, the ...
5
votes
1answer
259 views

pgfplots ybar plot with 2 y axes and equal shift on x axis

I am trying to create a ybar plot with two y-axes and proper alignment on the x-axis. I have two data sets to compare and what I'm trying to get is the look of a normal ybar plot with horizontally ...
1
vote
1answer
351 views

PGF barplot with two y axis

I added a new axis to my barplot and that has a different scale as the first one. The second axis is shifted and does not have the same height as the first one. What do I need to change so that the ...
3
votes
1answer
117 views

Tikz stacked ybar chart shows incorrectly when I change the lower limits of the y axis

I have a problem with my picture generated using the tikz package. I would like to represent a y-stacked bar plot with the correct axis scaling. When I put the lower limits for the y-axis at -100 or ...
3
votes
1answer
184 views

Adding lines to bar charts

Is it possible to add a straight horizontal black line (from (0, 0.4) until the very end of the graph) in a bar chart environment like this: Here is the code that generates this bar chart (borrowed ...
2
votes
1answer
478 views

How to correct nodes near coords position in ybar stacked?

I'm working with this ybar stacked graph, but I can't position the nodes near coords in a correct position (not over something, not outside the chart, not over other bar, not to far away...readable!). ...
3
votes
1answer
110 views

Show mark labels near marks and not centered in ybar interaval graph

I'm doing a graph with vertical bars (ybar) where each bar represents not a number (1) but a class ([-0.5,0.5]). I would prefer that tick labels on the x axis appeared near the ticks marks, so ...
4
votes
1answer
237 views

How to hide empty (value 0) ybars with pgfplots?

I'm making a ybar graph (vertical bars) where the y axis maximum reaches 150+, but a lot of values are 0's. I would like the final graph would not show a minimum bar in this 0 values, since we this ...
8
votes
1answer
293 views

Histogram: different color for each bar

I have the following code. \documentclass[a4paper,twoside,12pt]{article} \usepackage[T1]{fontenc} \usepackage[utf8x]{inputenc} \usepackage[english]{babel} \usepackage{pgfplotstable} \definecolor{...
3
votes
1answer
409 views

pgfplots 3D bar chart - wrong plotting order

I am using bar3 to plot 3d diagrams in Matlab but it seems that in LaTeX the plotting order is wrong ? Is there any way to have the right order? This is a small example of the generated 2.tikz file ...
1
vote
0answers
33 views

Eliminating excessive spacing in bar graphs

How can I eliminate the spacing to the left and right of my bar graph? \documentclass[12pt]{report} \usepackage{pgfplots} \usepackage{tikz} \begin{document} \begin{figure} \begin{tikzpicture} \...
5
votes
1answer
788 views

Combining line chart data with bar plot

Context I recently got a paper published and was told that I need to convert the word file I submitted to latex for camera ready purposes. Problem is, I don't know LaTeX but I have always wanted to ...
3
votes
2answers
382 views

Bar plot in pgfplots using a palette using only fill

I am trying to create some nice looking bar plots, but this does not seem to be an easy task for me :) I have started out with the following: \begin{tikzpicture} \begin{axis}[ xbar, xmin=0, ...
3
votes
1answer
177 views

Adding a trend line to a bar chart

I'm very new to LaTeX, preparing my very first document in the environment and learning on the way. I've encountered a problem with one of my plots - I'm trying to add a trend line to a bar chart to ...
2
votes
1answer
276 views

Broken bar diagram with tikz package

I am trying out tikz package to create bar diagrams and following the code example in the manual on page 82 http://ftp.fernuni-hagen.de/ftp-dir/pub/mirrors/www.ctan.org/graphics/pgf/contrib/pgfplots/...
0
votes
0answers
168 views

Customize PGF bar chart bars

Ideally, I'd like to write a macro which specifies how to draw the bar of a PGF bar chart, given its height, width, and location. This seems nearly equivalent to asking how to specify a non-repeating ...