{pgfplotstable} is a package that can read, parse, modify or generate tables. Data is provided via either external files or inline code. It also serves as the data handler of the graphics package {pgfplots}.

learn more… | top users | synonyms

1
vote
1answer
107 views

PgfPlots Histogram: wrong density on y-Axis

I want to make a pgfplots histogram to visualize the jitter of a 260 MHz clock signal. I want to use the probability density on the y-Axis. Yet, when I try this, the y-Axis does not display the ...
3
votes
1answer
53 views

Why does conditional formatting and dec sep align render values twice?

I want to use dec sep align and conditional formatting at the same time. Separately I managed to make them work, but together they double every value in the column. \documentclass[]{article} \...
4
votes
1answer
110 views

Problem defining a string column with PGFPlotsTable

First, I am fresh new with the PGFPlotTable package! I have the following CSV file that I would like to plot in a LaTeX table: truncatedtime;meanfinalfloatvalue;floatvaluedifference;datap2count;...
4
votes
1answer
320 views

PGF Math Error: Could not parse input as a floating point number

I am trying to print a table from .dat file. In the file there are some columns that are not numbers but words and I think this is the reason why I have this error. How can I fix it? \documentclass[...
1
vote
1answer
165 views

Setting “col sep = semicolon”

I obtain this table: using this code: \pgfplotstabletypeset[ col sep = comma, string replace*={_}{\textsubscript}, every head row/.style={before row=\toprule,after row=\midrule}, every last row/....
6
votes
1answer
282 views

Place node at local maxima or minima of graph

Though there is an upvoted answer - the question is NOT answered. It turned out, that without smooth the resulting figure gets produced and looks alright, but the error remains. How to get rid of ...
4
votes
0answers
126 views

Calculate x-coordinate for given y-value by interpolating data from pgfplotstable

I have a text file data.txt with the following content: -2 -2 +1 +0 +1 +3 +2 +4 +2 I read it with \pgfplotstableread{data.txt}\data and then plot the second column by the first column with \...
2
votes
0answers
39 views

Adding a Trend Line to a dateplot

How could I add a trend line to this plot? Many thanks! \begin{tikzpicture} \begin{axis}[ date coordinates in=x, xtick=data, xticklabel style= {rotate=90,anchor=near xticklabel},...
3
votes
1answer
32 views

Marking single table values with dot alignment

I have a table with multiple columns that I have aligned with the S column type from siuntx. In each column I want to mark some special values in a clear and subtle way, I've used the * symbol for ...
4
votes
1answer
133 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
254 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 ...
2
votes
1answer
99 views

Align inline tikz nodes text with current line text (in table)

I have this table, where the first column has inline tikz nodes. I would like the text of the nodes to be vertically aligned with the text of the table. I found this question about his (among others),...
3
votes
2answers
120 views

How to only truncate pgfplotstable integer entries, but not rounded floats?

I have a csv file conaining differently precise numbers. Now i want to plot them with precision=1. The reader should see that some values are integers, so the respective number should be shown without ...
4
votes
1answer
227 views

How to highlight pgfplotstable cells with bold font while preserving number format?

I want to highlight cells in my pgfplotstable, but the bold font setting overwrites my number format. How to prevent this? Here is a MWE: \documentclass[12pt]{standalone} \usepackage{filecontents} \...
2
votes
1answer
98 views

How do I format a range of pgfplotstable columns at once?

I want to set a range of columns (1,2,3 in the MWE below) at once without overwriting the formatting of the first column. Therefore, I don't think an "all" columns solution is applicable. \...
5
votes
2answers
147 views

How do I automatically multiply columns by 100 to get percentage numbers in a pgfplotstable?

I have a csv file with percentages to load into a pgfplotstable. I already format them with siunitx but I did not find a possibility to shift the decimal point (multiply by 100) to get percentage ...
2
votes
1answer
99 views

Math symbols in pgfplotstable

Suppose I have a file numbers.txt, whose contents are x y 1 2 3 4 50 20 I want to put this into a table using pgfplotstable, but while these numbers can change I want an additional ...
6
votes
1answer
207 views

Stacked bar plot, percentage of entire bar and the total value

I have made quite a lot of progress of where I want to be, but there is still some fixes to be made. What I have right now as an image: However, as we can see, the percentage are all relative to ...
1
vote
2answers
76 views

pgfplotstable missing error and strig type

I have searched for solution to my problem on using pgfplotstable, but I didn't find nothing useful. I'm using pgfplotstable to import csv data into my latex code. My table has four columns. The ...
1
vote
1answer
64 views

substring in addplot table

I want to add a figure which x label is symbols. But in data, the x label is longer than the figure's (because x label is abbreviated in figures). I want to know how to plot this kind of figure. The ...
1
vote
0answers
47 views

Preload and preprocess data with pgfplotstable for use with \addplot

I'm creating grouplots for various datasets. Apart from some y-values, they all share the same x-values. In the past I used something like this to do the task: \addplot table [x index = 0, y expr = \...
5
votes
1answer
62 views

Align pgfplotstable in enumerate

I want to align a table created with pgfplotstable to the top in an enumerate environment, but instead it's aligned to the center. How can I fix this? I'm looking for something like the [t] option for ...
1
vote
1answer
70 views

siunitx produces number too big error with large numbers

minimal (non)-working example: \documentclass{article} \usepackage{siunitx} \usepackage{pgfplotstable} \usepackage{filecontents} \pgfplotstableset{ header=true, trim cells=true, col sep=comma, ...
1
vote
1answer
41 views

Problem centering subfloat

Try running this code removing one by one each \pgfplotstablegetelem. You will see that the 2 subfloats will move step by step to the center. Why? Keeping all of them the result is the following. I ...
2
votes
1answer
336 views

PGF plot color map contour plot from matrix data

I have succeeded plotting list data, generated from Matlab, as a contour in tikz-pgf using gnuplot. The data is arranged as 1,-6.2832,-6.2832,0.74038 2,-6.2832,-6.1563,0.74997 3,-6.2832,-6.0293,0....
1
vote
0answers
54 views

pgfplots - Define a extra x tick for the x interaction of a regression line

I have a regression line of some points and need a extra x tick at the x interaction of this regression. I could just calculate the value and make the tick by extra x ticks={x1} but I have to make ...
3
votes
1answer
63 views

characteristic of a regression line

I have a little Problem with a regression line I made. I need it to be from its zero up to the x-value of the highest point. This is how it actually looks und underneath how I need it. Does anyone ...
1
vote
0answers
72 views

single plot from rows of two files

I'm trying to plot data coming in from two different files. I want to combine the rows. So in \addplot I try to plot the data from both the files blindly expecting tex to combine them on a single plot ...
1
vote
0answers
35 views

Remove default formatting from pgfplotstable. [closed]

I have some tables created using pgfplottable loading data from a csv file. The issue I am encountering is that the values are getting reformatted, for example a "2.00" in the csv is resulting in "2" ...
1
vote
1answer
87 views

Get element from array

considering the generic table \mytable, to get an element from there I am using \pgfplotstablegetelem{\row}{[index]\column}\of\mytable. but if I don't have a table but an array? the case is this: \...
5
votes
3answers
215 views

Drawing a really large binary matrix as colored grid

I have a 50x300 binary marix, which I want to display as a colored grid. I tried the approaches of drawing a large binary matrix as colored grid which I like, but the approach using pgfplots table ...
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
0answers
122 views

Pgfplots: Transpose headrow as first column in: confusion matrix with colormaps / heatmaps

My question builds on code from this question: original question/answer What I am trying to achieve: I want to use pgfplots to build a table, where the header row is automatically added as first ...
3
votes
1answer
136 views

Get element from a table

I have the following table: \begin{filecontents}{table.dat} a 0.70 b 0.58 \end{filecontents} and I am trying to access at the elements with the command \pgfplotstablegetelem{0}{0}\of\table but ...
2
votes
1answer
84 views

Pgfmath misbehaving when reading negative values from table in Pgfplots

I am astonished that when I attempt to square a number read from a table with pgfplots, the result has the same sign. Consider this: \documentclass{standalone} \usepackage{pgfplots} \usepackage{...
2
votes
1answer
412 views

Importing table from csv file

I have the following table in a avg_value.csv file: ,M23,F23_1,M36,F44,F63,M70 M23,1.00,0.81,0.88,0.83,0.41,0.82 F23_1,,1.00,0.52,0.56,0.25,0.94 M36,,,1.00,0.62,0.94,0.96 F44,,,,1.00,0.43,0.23 F63,,,,...
3
votes
0answers
214 views

import a long tab delimited data file with first row as the header

Here's a very simple task that I don't seem to be able to get the format right. In short, I am trying to import and format a long tab-delimited txt file, with the first row as the header. I tried the ...
2
votes
1answer
61 views

pgfplotstable - apply formatting to a range of rows

I'm looking to change the formatting (specifically the background color) for a range of rows using pgfplotstable. It is easy enough to do this for one row, e.g. the 6th row, using: every row no 6/....
5
votes
2answers
171 views

function epigraph possibly using fillbetween

I want to shade and label the epigraph (region above a function) of different functions in latex, and have tried to use fillbetween, though im not quite sure how to do this as usually I specify two ...
5
votes
2answers
347 views

Plotting triangle on voronoi diagram, shading fractions of triangles with pgfplots/Tikz

Using this previously asked question I was able to plot Voronoi polygons from a set of generated data. I would like to annotate the plot further by doing the following: SOLVED BY MANIPULATING INPUT ...
1
vote
1answer
116 views

Date/Time in both axes with PGFPLOT

I am trying to plot some data that contains date/time values in both the x and y axis. I have been using the pgfplots and have managed to plot date/times on the x axis and on the y axis separately ...
3
votes
1answer
108 views

How to correct a PGFPLOT plot with minimal data that does not follow global options?

I have incomplete test data, as shown in the MWE. I would like to use all (few) available data points in the plot, ie (55.16, 0.08) for copper, but the plot does not take it into account. Also the ...
3
votes
1answer
86 views

beamer presentation with each figure on each slide using a foreach and pgfplots

Im doing a beamer presentation. With pgfplots I need to load a single column of a data file like this: 1 10 50 -50 2 11 51 -49 3 12 52 -48 4 13 53 -47 5 14 54 -46 6 15 55 -45 ....
2
votes
1answer
49 views

plot and fit from pgfplottable

I would like to plot a graph from data created inside pgfplottable. I have one file of data data.dat: x,y 1,2 2,3 3,4 4,5 5,8 6,9 7,34 And this code : \documentclass{beamer} \usepackage{etex} \...
1
vote
1answer
47 views

Pgfplots not working with Pgfplotstable

I am writing a document using LaTeX which must contain both graphs and tables. For the graphs I have been using pgfplots and this has worked brilliantly. Now I needed to insert a few tables and was ...
2
votes
1answer
59 views

Which command to get words from table?

I have the following table: \begin{filecontents*}{table.dat} cane 1.5 gatto 3 \end{filecontents*} from which I have to take cells separately for the plot. The numeric values can be easily gotten ...
1
vote
0answers
186 views

print empty cell in Latex

I have an array stored in csv file from Python program as : W = [ 1, 2, , 4, , 5] I want to print the array in Latex as : W 1 2 4 5 I have ...
3
votes
1answer
141 views

Can you use `pgfplotstable` to do a linear regression to an expression?

I have a lot of data in a table, but it is not linearly related. I can linearize the relationship by computing functions (x expr and y expr expressions). I would like to use pgfplots to show the ...
2
votes
1answer
105 views

Regression with .csv tables

I am having trouble getting regression to work. If you wouldn't mind just looking over the code and point me in the right direction I'd really appreciate it. I have loaded pgfplots and pgfplotstable ...
3
votes
1answer
129 views

Colored circles from data

I have a data file which gives x-position (xpos), radius, and color. I wish to draw a circle at ever (xpos,0) with appropriate radius and color. How do I achieve that? I have used two approaches. ...