{pgfplots} is a package for creating 2D and 3D plots of mathematical functions and numerical data, using the PGF graphics framework. For questions about the inbuilt plotting functionality of TikZ/PGF, use {tikz-pgf} instead.

learn more… | top users | synonyms

9
votes
0answers
397 views

XeLaTeX and TikZ - how do I ensure my PDFs are using the CMYK color model?

The place I want to print my document at needs the PDF to be provided in CMYK. The document is mostly text, except for a few graphs and plots which are done in TikZ or pgfplots. As suggested in this ...
6
votes
0answers
142 views

Different color

I use the following code to generate a plot \documentclass{article} \usepackage{xcolor} % colorize your documents \usepackage{graphicx} % and use graphics \usepackage{tikz,pgfplots} % ...
6
votes
0answers
73 views

Automatically add discontinuities in some plots

I have multiple plots (about 15 different figures) that have the same axes (i.e., same ymin and ymax values and same xticks). One of the plots has very large values. I don't want to either increase ...
6
votes
0answers
312 views

Resizing pgf plots in an A0 beamer poster

I am creating a A0 scientific poster with the beamerposter package and I want to include TikZ/PGF plots. However, if I typeset these plots, the line width for the axis and for the data are too small. ...
6
votes
0answers
308 views

Switching math fonts and back to normal fails in figures?

For my current document I want to use a normal serif font for the main text. Most diagrams from other sources and myself are with sans serif fonts (TeX Gyre Heros). Now I want to use pgfplots to ...
5
votes
0answers
45 views

pstool + pgfplots + parskip conflict

I've recently observed extremely strange latex bug if pstool + pgfplots + parskip packages are used at the same time. \documentclass{article} \usepackage{pstool} \usepackage{pgfplots} ...
5
votes
0answers
413 views

Trying to make an automatic histogram (in pgfplots?)

How can I convert the automatic table generated by the macro, to an automatic histogram? Is the best way do it using pgfplots? \documentclass{article} \RequirePackage{ifthen} ...
4
votes
0answers
60 views

Pgfplots : Shadow in bar chart with restricted domain

I have a following code which plots a pgf bar plot for me. I am able to add shadow to one of the bar plot. However, the other plot which has a broken y bars, I am unable to add the shadow, because ...
4
votes
0answers
94 views

grouped bar colors in pgfplots

I have a simple grouped bar chart but would like to have all group bars the same color. Currently each bar in a group is colored, possibly because of the way I have used addplot. I've tried to use a ...
4
votes
0answers
155 views

Multiple ternary plots and pie charts in pgfplots

I'm trying to plot lots of ternary plots and pie charts. Ideally it should look smth like this: The pie-chart (ternary plot) on the left-hand side serves as an explanation of what is happening, ...
4
votes
0answers
119 views

Tick labels in pgfplots data time format

I tried to plot a data set containing seconds and milliseconds with pgfplots. I’ve found a solution for my task here (pgfplots data time format), which I changed a bit. This principally works very ...
4
votes
0answers
106 views

Problems with pgfplots, loops inside tikzpicture and reading from files

I was trying to implement this method (How to import ASCII coordinates to TikZ) to import coordinates and draw them, but I am having this problem Undefined control sequence \end{tikzpicture} Extra }, ...
4
votes
0answers
110 views

pgfplots: Plot only parts of table and in “random” order

I have been lurking around stackexchange for a long time and so far been able to find solutions for my newbie problems but now I'm really stuck! My problem is probably not that complicated, yet a bit ...
4
votes
0answers
172 views

Convolve two 2D Gaussians using tikzfading - intensity issues

I would like to visualize the convolution of two 2D Gaussians (or something looking similar). To do this, I declare them in a tikzfadingfrompicture environment. However, to get the desired result and ...
4
votes
0answers
59 views

Plots with “no marks” have marks in references

I want to plot some functions without marks and reference them in my text - the problem is that in the text there are some random marks and i can't turn them off somehow. \documentclass{article} ...
4
votes
0answers
71 views

question on pgfplots and pos=

In pgfplots, pos=a , with a between 0 and 1, refers to the relative x coordinate on a plot. I was wondering if there is an equivalent construct that accept the absolute x coordinate rather than the ...
4
votes
0answers
85 views

Let ymin be at most 0

I would like to make a graph of some points, where ymin is at most 0. By default, ymin is the value of the lowest point in the graph. I would like to let ymin be the value of the lowest point or 0 if ...
4
votes
0answers
209 views

legend problem in highlighting a data plot

I followed the tips on highlighting in data plots at http://www.howtotex.com/tips-tricks/highlighting-in-tikz-plots/ The highlighting does not work well with \addlegendentry. A MWE is shown below. ...
4
votes
0answers
539 views

Tikzscale, trim axis left/right, and externalizing

tikzscale and trim axis do not play well together, with the produced figure being larger than requested because it ignores the size of the labels. I was wondering whether it is possible to use both ...
4
votes
0answers
277 views

using bar chart to compare two groups of data, how to draw one node (showing the ratio) per two bars?

I have two groups of data, you can think of them as one control group and one treatment group, and each data point shows the system's performance under certain parameter x. Now for each value of ...
4
votes
0answers
167 views

pgfplots: percentages and endvalues in stacked ybar

I have two questions regarding the pgfplots package. I have attached the source code I worked on. There are two features I am not able to realize: I would like to put the total value (sum of the ...
4
votes
0answers
213 views

Using `external` selective for TikZ-pictures

For the following example: \documentclass{beamer} \usepackage[utf8]{inputenc} \usepackage{tikz} \usetikzlibrary{calc,external} \usepackage{pgfplots} \tikzexternalize \begin{document} ...
4
votes
0answers
121 views

Increasing dateplot's resolution to seconds

These three dots should be spread out over a period of 50 seconds, but for some reason they all appear at 13:00:30. \documentclass{minimal} \usepackage{pgfplots} \usepgfplotslibrary{dateplot} ...
4
votes
0answers
451 views

Matlab2tikz adds extra legend entries

The legend from a boxplot figure is not being created properly. I get this: Instead of thiS: But really only need 2 legend entries. Any Ideas why all the objects in this plot are being given ...
4
votes
0answers
413 views

How can I display negative error bars in a logarithmic plot using pgfplots?

I have error bars representing 95% confidence intervals in a logarithmic plot. Some of the error bars extend to negative numbers for which the logarithm is undefined, so pgfplots simply drops the bar ...
4
votes
0answers
372 views

Decorate pgfplots mesh

In my quest to solve this question I'm trying to see if I can decorate a mesh-plot by drawing many circles or maybe rectangles with a radius determined by \pgfplotspointmetatransformed. But I can't ...
3
votes
0answers
24 views

PgfPlots bar with missing data causes columns to be “misplaced”

I looked for a similar problem here in SE but I couldn't find it. It's just driving me crazy :| Here is a MWE: \documentclass[xcolor=dvipsnames, 10pt, pdflatex]{beamer} \usepackage[utf8x]{inputenc} ...
3
votes
0answers
58 views

How to automatically optimize the PDF output of TiKZ externalize?

I use pgfplots with externalization for generating plots in my document. For heavy plots the output PDF for a figure can grow to few hundred KB. I used Adobe Acrobat to optimize the PDFs which ...
3
votes
0answers
79 views

pgfplots: unable to affect cycle list name while using \pgfplotsinvokeforeach

I am unable to use custom colors from cycle list name with pgfplotsinvokeforeach. Some pointers could be gauged from this post, which discusses execution of various steps in a plot function. In the ...
3
votes
0answers
70 views

External PDF from pgfplots contains several pages when with floatrow

Plotting with pgfplots and the external library creates the single PDFs for every plot as wanted. But every of those PDFs contains several pages, each showing the same plot. Sometimes there are three ...
3
votes
0answers
161 views

Decorating a PGFPlots bar graph with Tikz decorations

Update :- This appears to be a problem in which nodes near coords are handled by PGFPlots and incompatibility with Tikz decorations and fading library. I simply commented the nodes near coords line ...
3
votes
0answers
60 views

tikzscale and \tikzsetnextfilename

I'm using Windows 7 or 8.1 with MiKTeX 2.9. I still have the problems, described here and here. I updated the packages with the package manager and I use \documentclass{report} ...
3
votes
0answers
64 views

How to automate right node alignment for labels from table AND marker size AND marker color of scatter plot?

Problem: Labels from table are placed right, but overlap. Is there a way to automate alignment of the labels near nodes so that labels do not overlap? This is a small example but I have bigger table ...
3
votes
0answers
98 views

How to color groups of bars in a graph, coming form an external file?

I have a graph displaying bars and error bars, the numbers comming from an external .dat, being simply black and white. And this is how I got there: \documentclass[12pt]{report} ...
3
votes
0answers
173 views

Normal probability plot with percentile grid and axis

How can I make a normal probability plot with a percentile grid and y-axis as shown in figure? I've read the pgfplots documentation but i can't find anything useful.
3
votes
0answers
55 views

Pgfplots fails to generate boxplots for some data set

I use pgfplots to generate boxplots, however with some small data sets as the following, I get an error message. speed 2 3 1 2 2 11 Here is the error message : Sorry, an ...
3
votes
0answers
152 views

pgfplots - divide y-axis in 2 parts

I have a plot, code here. Now the problem I have is that because of the scale of y-axis it looks as if the plots are actually just 3 lines. Now what I want is that the y-axis is sort of splitted. Into ...
3
votes
0answers
294 views

PGFPlots: importing data from a txt file

So I imported data from two txt files. However, I would like to plot the mean of the data and then the standard deviation bars. How can this be done? \documentclass[tikz, convert = ...
3
votes
0answers
304 views

TikZ graph not aligning

I am having two issues with TikZ pictures. I have three graphs side by side, and I am having issues, but only with some of them, which is very odd. First the x-axis is going out of alignment (some ...
3
votes
0answers
168 views

Common label for a groupplot

This can be considered a combination of the following questions How can a title be placed for a group of pgfplots? Align ylabels of grouped plots at a common line The following piece of code ...
3
votes
0answers
273 views

Clustered Stacked bar Chart Overlapping Labels

I have following code by which I generate the following graph \documentclass{article} \usepackage{pgfplots} \usepackage{tikz} \usepackage{xcolor} \usetikzlibrary{arrows,automata,calc,shapes, ...
3
votes
0answers
194 views

drawing lines using polar axis coordinate system in pgfplots

I would like to draw arrows with polar axis notation in a pgfplots figure that has Cartesian axes with the draw command: \draw[->] (polar axis cs:radius=1, angle=30) -- (polar axis cs:radius=2, ...
3
votes
0answers
194 views

pgfplots trim to axis area even with extra ticklabels

I have a plot with extra x tick labels on top in pgfplots that i wish to display in a figure at the top of my page. I wish to have the top of the actual axis rectangle directly at the top, with the ...
3
votes
0answers
188 views

Using pgfplots and gnuplot and compiling with output-directory

I would like to use the pgfplots package along with gnuplot. However, I cannot get this to work if I compile using the -output-directory option. For example, if I have the following MWE: ...
3
votes
0answers
194 views

Relative coordinates in pgfplots across multiple table plots

This is a follow up question to this one: Use pgfplots \addplot plot coordinates with relative coordinates Is it also possible to have the relative coordinates across multiple plots? For example if ...
2
votes
0answers
62 views

using gnuplot to plot data from a file

I am trying to plot some data using pgfplots, but the data are so extensive that the maximum capacity is reached. I get the error: TeX capacity exceeded, sorry [main memory size=3000000]. What can I ...
2
votes
0answers
37 views

pgfplots stacked bar chart with markers

I have a stacked bar chart. I would like to add markers to the chart in some values. I am trying to create something like in the stacked bar chart. Is it possible to add markers instead of another ...
2
votes
0answers
28 views

everyshi.sty is missing, how to install

I'm trying to use the package pgfplots, and I have successfully installed it along with the pre-requisite pgf. Whenever I compile, I get the error message "The required file ...everyshi.sty is ...
2
votes
0answers
70 views

pgfplots: problem with stacked histograms

I want to plot data for a node that has several inflows and one outflow, using stacked histograms. I want the plot to look like this: First, I have tried stacked histograms (ybar stacked, see the ...
2
votes
0answers
99 views

Generating Gantt Charts for process scheduling

I am trying to create a gantt chart for my thesis on blocking analysis. I know of the pgfgantt package for generating gantt charts. But this package generates charts for normal schedules, what I need ...