{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

2
votes
0answers
226 views

Strange behaviour of pin angles with PGFPlots [duplicate]

Possible Duplicate: How can I force TikZ pin angle? TikZ node pin angle in 2D plot I need to have some marks in a diagram pointing at characteristic points of the plot. To not have the ...
15
votes
1answer
4k views

Custom Dashed Plot Lines in PGFPLots

I know that you can make a dashed line in pgfplots using the \addplot[dashed] option. However, the line that produces isn't dashed the way I'd like. I found \pgfsetdash in the documentation for ...
7
votes
2answers
948 views

2d graphs in a 3d plot [closed]

I am trying to create 3d plots with several 2d graphs, like in Plotting several 2d functions in a 3d graph. However the end result looks like this: Using \closedcycle doesn't help either, as it ...
23
votes
3answers
3k views

How can I make plots with TikZ which look like the new Mathematica 9 plots

The new Mathematica 9 is out! I would love to know how to make similar plots to the one's advertized, particularly the following: and Here is a simple plot to get started. %& -shell-escape ...
5
votes
1answer
373 views

Some issues concerning a plot created as a `tikzpicture`

The above tikzpictureplot was created mainly adapting the code of Create xkcd style diagram in TeX . I located the dots and labels by trial and error. What are the better options? To create the ...
8
votes
1answer
1k views

Line in front of marks

I am creating plots that contain a LOT of data points, and each plot also includes a line that is independent but coincident with those points. The problem is that the marks get in front of the ...
6
votes
1answer
2k views

'only marks' option breaking cycle lists

I am trying to create a series of plots where data is presented with fitted curves, so what I need is for the data plots to be scatter plots with hollow marks and the fits to be solid lines with no ...
4
votes
1answer
1k views

PgfPlot: Axis Arrows vs Vector Arrows

I've notice that the arrowheads on the axis are different than the arrowheads drawn when drawing vectors: \documentclass{article} \usepackage{pgfplots}\pgfplotsset{compat=1.7} \begin{document} ...
18
votes
1answer
3k views

Simpler boxplots in pgfplots - is this possible?

When I wanted to plot boxplots in pgfplots, I started using the solution proposed by Jake in the question linked to above. However, as I wanted to plot more than one set of boxplots in the same figure ...
2
votes
1answer
133 views

How to change to dotted style

How to change the line style to line style with different line style such that people need not to have a color printer to view it? \pgfplotsset{mystyle/.style={mark=none}} \begin{tikzpicture} ...
7
votes
1answer
778 views

pgfplots: labels and width issues in non-boxed 3d plot with oblique projection

Update april 2013 The bug has been fixed with pgfplots version 1.8 (requires \pgfplotsset{compat=1.8}). When I try to add the axes labels to this code, I get a division by zero error. I think the ...
3
votes
1answer
954 views

How to draw a dashed line with *-mark + error marks + a line in foreground in the same plot with pgfplots?

I create a plot with pgfplots with the following code: \documentclass{standalone} \usepackage{tikz} \usepackage{pgfplots} \pgfplotsset{compat=1.6} \begin{filecontents}{ExampleData.txt} xValue1 ...
4
votes
1answer
529 views

Filling “symbolic y coords” automatically with the content of a table row

Is it possible to fill “symbolic y coords” automatically with the content of a table row? I have many data to plot and it would be very cumbersome and laborious to do it manually. Best regards ...
15
votes
2answers
715 views

Bar plots in sans serif font

I want to typeset my bar plots with a sans serif font (using LuaTeX). I tried many options that I found searching the manual and the internet. None of them solved my problem---using different fonts ...
6
votes
1answer
914 views

Discontinuity of log axis in pgfplots

Using log-scale for bar charts is probably not a good idea due to the lack of a true zero. However, given skewed data, there doesn't seem to be much alternative ... otherwise smaller values get too ...
9
votes
1answer
363 views

Long yticklabels increase height of bar plot too much

With the help of Jake I'm able to create bar plots with variable heights ( Space between bars, height and width of the plot ). Some bar plots have single very long yticklabels that need line breaks. ...
8
votes
1answer
731 views

Correctly align vertical text on a baseline in pgfplots

I'm proud to announce that I have a large number of PGFplots in my document. But ... I have a small problem with the vertical alignment of text throughout my plots. What's the easiest way to align ...
5
votes
1answer
213 views

Using continuous curve without points

is it possible to use a curve without specific point to represent the data, the reason is that the data has too many points to display correctly. This is what I have (It looks all messed up) This is ...
4
votes
1answer
797 views

Move legend closer

I wish to move the legend for the left chart closer to the graph, and for the right graph, I wish to let the x-axis and y-axis appeared just like the left graph (so that there is some extra spaces to ...
11
votes
1answer
3k views

Space between bars, height and width of the plot

I'm using pgfplots to generate bar plots from data files. Here's MWE: \documentclass{article} \usepackage[ngerman]{babel} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis}[ ...
2
votes
1answer
1k views

Adjusting features of a pgf plot

I have the pgf plots below, where it doesn't appear well. I wish to put closer the "Solving Time(ms)" and y axis, put the font size smaller how should i do it? There is also a problem for ...
6
votes
1answer
963 views

“Dimension too large” for pgf plots

I have code below which complaining "Dimension too large", what is the problem? And I want to zoom in the 99.8-100 rather than using log scale for y axis, how should I do it? \documentclass{article} ...
1
vote
0answers
405 views

tikz foreach used for number in filename for addplot [closed]

I have quite a few tables generated which I want to plot in the same TikZ figure (using pgfplots). I am currently trying to use a foreach loop to plot them all, but it is only plotting the last ...
21
votes
2answers
17k views

How to plot data from a CSV file using tikz and csvsimple?

Here is a minimal example : \begin{filecontents*}{data.csv} a,b,c,d 1,4,5,1 2,3,1,5 3,5,6,1 4,1,4,9 5,3,4,7 \end{filecontents*} \documentclass{article} \usepackage[utf8]{inputenc} ...
6
votes
2answers
3k views

pgfplots input parse error with expression

Hi there I got the following problem at hand. I load my plot data automatically from an external .csv file and manipulate it via a simple expression (conversion from ms to seconds) before plotting it ...
8
votes
1answer
256 views

pgfplot change label from axis

I have created this plot with tikz \documentclass{article} \usepackage{tikz} \usepackage{pgfplots} \begin{document} \begin{tikzpicture}[scale=0.9] \begin{axis}[ xlabel=$\alpha$, ...
3
votes
1answer
220 views

Why do I get an incorrect graph when I plot a function with multiplication expressed by parentheses?

When plotting certain expressions with pgfplots it seems to give the wrong result. Consider the following \documentclass{article} \usepackage{pgfplots} \pgfplotsset{ compat=1.7, no marks } ...
23
votes
2answers
5k views

Fill the area determined by two pgfplots graphs

I need to fill the region determined by two (Gaussian) curves and the right red line (the region is brushed in green in the figure below). I also wonder what is the best way to draw vertical line ...
3
votes
1answer
325 views

pgfplots: marks in table as ellipse with size of error bars, area of uncertainty?

Is it possible, and if yes how, to plot a table with pgfplots where the marks are ellipses with the major and minor semiaxes being the size of the error? Such that a data point is displayed as its own ...
5
votes
1answer
2k views

How to specifiy xticks in log-axis mode (tikzpicture) to be written in non-exponential format?

I want to specify some xticks in a log-log plot (tikzpicture). This works fine, but they are always printed in exponential format (with basis 10). In general this is fine, but for one plot I would ...
3
votes
1answer
139 views

Make the label surrounding line disappear

Referring to How to plot the graph below? Is it possible to make the label surrounding lines, and the top and right lines for the coordinates disappear?
5
votes
2answers
425 views

How to plot the graph below?

May I know how to draw the graph as shown below? below is a code I have try but with look and feel that is quite far away from the example: \begin{tikzpicture} \begin{axis}[ legend pos=north ...
8
votes
1answer
19k views

Put legend (pgfplots) below the plot

I have a pgfplot where the legend is right to the plot. I create the plot as follows: \begin{axis}[ scale only axis, xmode=log, ymode=log, width=7cm, legend cell align=left, ...
2
votes
1answer
525 views

pgfplots: fill the volume under a 3d surface

I have a very simple 3d graph. \begin{tikzpicture} \begin{axis}[view={60}{20}, %axis equal image=true, xlabel=$X(T)$, ylabel={$D(T)$}, zlabel={$V(T)$}, zmin=0 ] \addplot3[surf,shader=flat,z ...
6
votes
1answer
904 views

Common scale for pgfplots groupplot

The groupplots environment allows global values of xmax to be set. Is there a way to automatically select a common value for all plots in a group? For example, with the code below, the 4th plot does ...
8
votes
2answers
939 views

Strange error bars problem

I'm trying to get error bars to show correctly on my plot using pgfplots. I am wanting explicit relative error bars in both directions for my y-data, and what I am getting is perplexing. The error ...
7
votes
3answers
589 views

Calculate function with integers as input and plotting

I'd like to plot the function 1/2*x(x+1) in for integer values ranging from 3 to 20 and in particular I'd like the function to be plotted in those points. I have managed to create the following graph ...
11
votes
1answer
846 views

how to draw interrupted bar charts in pgfplots

Is there a way to interrupt the bar charts in pgfplots? More specifically, I have a plots with bar charts and one chart has extremely high values, so that you can hardly see the others in a scale. ...
27
votes
1answer
15k views

Option clash for package xcolor

I'm writing a report, and have a rather large table in my appendix. I'd like to emphasize some specific values by coloring some single cells. I'm trying to do it with xcolor. But receiving the error: ...
8
votes
1answer
3k views

How to vertically align two pgfplots in subfigures?

I want to have two subfigures in a figure. Each subfigure contains a simple pgfplot. Here is what I have: \documentclass[12pt]{article} \usepackage{subcaption} \usepackage{pgfplots} ...
3
votes
0answers
403 views

pgfplot gives an error despite using the latest version v1.7 [closed]

I keep getting this error every time I compile using the pgfplot package "! Package pgfkeys Error: I do not know the key '/pgfplots/error bars/ .cd' and I am going to ignore it. Perhaps you ...
1
vote
0answers
60 views

PGFPlots fixed number formatting fails on small numbers [duplicate]

Possible Duplicate: How do you remove the axis multiplier? I have a problem getting fixed (as opposed to scientific) number formatting on my axes in PGFPlots. The following example: ...
5
votes
1answer
271 views

Plot weighted frequency matrix

I wish to create this plot preferably in pgfplots or tikz. I have actually got a version plotted (with help from SO), but I have used R and exported the plot using tikzDevice. I can't post the ...
6
votes
1answer
568 views

pgfplots: \thisrowno{} is an undefined control sequence?

A lot of code about pgfplots I found (also here on tex.stack) was using \thisrowno{} to address specific rows of a table. All of these had no additional pakages loaded than I do in the following ...
6
votes
2answers
3k views

pgfplot column chart legend shape

I have the following code in Latex using gpfplot. The legend in the generated graph always looks like the image attached. There are two boxes instead of one for each entry. Why this is happening? How ...
18
votes
1answer
2k views

Drawing timeline

I have a dataset which consists of repeating events over time. Each event takes an arbitrary amount of time. I could plot this using gnuplot but am unable to produce correct keys because of the ...
7
votes
5answers
840 views

How to create this image (graphing)

I want to create a graph with only the first quadrant. The values of x can only go from 0 to 9 and the values of y can only go from 0 to 9. In this graph, I want dots for (2,5), (3,3), (5,2) and ...
6
votes
1answer
278 views

Plots only logarithmicly spaced samples

I have a data file with many entries, order of 10000. I want to plot them all with lines, and a small subset of them with points and error bars (can not plot error bars on 10000 samples). Plotting ...
6
votes
1answer
812 views

Improve pfgplots precision with gnuplot

I have measured the execution time of two algorithms (a naive, and an optimized one), and I would like to display measured data with pgfplots plus a trend line for the naive algorithm. I have used ...
3
votes
1answer
928 views

pgfplots: scatter plot with interpolation

Today I have a question about scatter plots: Is it possible to interpolate scatter plots? In my work I often use "intensity plots" (that's how we call them). In these plots x and y are positions, ...