{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

3
votes
1answer
36 views

Automatic labelling of isolines based on table's column name

I would like my code to use the column name (from pgfplotstable) to automatically label the lines. Here is a MWE: \documentclass{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.13} \...
4
votes
1answer
24 views

How to prevent \rowcolor from overriding row lines in PGFPlotsTable?

A relatively new to PGFPlotsTables but find it very useful for formatting large tables and pulling in external data in LaTeX. However, I'm running into the following issue. When I want to color the ...
2
votes
1answer
36 views

How I can get get Null values in table using pgfplotstable?

I am creating a table using pgfplotstable in LaTeX. But the problem is, I want first column of table blank. But we never leave any values, table should be balanced in pgfplotstable.I define "nan" to ...
2
votes
1answer
29 views

Rounding off before plotting

Is it possible in latex to directly round off numbers from tables before plotting? I tried using round-precision from siunitx package, but this does not seem to work. MWE \documentclass{...
1
vote
1answer
25 views

Merge two .csv files and add missing rows?

I have two files. A.csv: date,colA 2016-01-01,1 2016-01-02,4 2016-01-03,2 And B.csv: date,colB 2016-01-01,2 2016-01-03,4 I'd like to combine these to get equivalent of: date,colA,colB 2016-01-...
1
vote
1answer
31 views

Best way to apply same style to data/theory pair-plots automatically?

Suppose I have multiple plots of experimental data series in one axis and that I also want to plot a theoretical prediction for each series. Is there any good way to group each data/theory pair ...
2
votes
1answer
22 views

pgfplotstable: conditional formatting by string value

I would like to extend the following example so that cells with YES in are colored green and cells that have NO in are colored red: \documentclass{article} \usepackage{pgfplotstable} \begin{...
5
votes
0answers
29 views

Skip some x tick labels when using `xtick=data`

I am plotting some csv data with \documentclass[border=10pt]{standalone} \usepackage{tikz} \usepackage{pgfplotstable} \usepackage{pgfplots} \pgfplotsset{compat=1.13} \begin{document} \begin{...
4
votes
0answers
38 views

pgfplots: Plotting one subfigure per country, from datafile

I have data in csv format at the country-year level, and using pgfplots I would like to plot a given variable over time, with one subfigure per country. My idea was to use a groupplot environment: and ...
6
votes
1answer
84 views

pgfplotstableread + addplot table: scale column for re-use

I get output files from a code and I want to display the output file with pgfplots. I want to create several different plots with the same files. Therefore, I read them in a macro with pgfplotstable. ...
6
votes
2answers
48 views

Precision setting lost when postprocessing rows

I want to generate a formatted table from a CSV file: with every other row in a different color using 4 digits precision for numbers Right now I can't seem to have both. Here's an example code to ...
1
vote
0answers
23 views

pgfplotstable: trouble reading data from file with leading zero

when i create a table within the process of LaTeX, i am able to access the items, for example in a loop. If i read a table from a file with "\pgfplotstableread" then it refuses to read in values with ...
2
votes
0answers
30 views

Mark local maximum and calculate gradient in PGFplots

I'm using data from a tensometer to generate a stress-strain curve, but I want to find the yield point and the gradient between the start of testing and that point to calculate Young's modulus. Can ...
1
vote
1answer
45 views

How to reference a cell outside pgfplots-table?

I have written a dynamic LaTeX table which includes data from an external file and computes a new column out of the existing columns according to some criteria. Now I want to reference the computed ...
1
vote
0answers
23 views

pgfplotstable, multicolumn sp

I am trying to make a table (code below) that should contain three headings and five equally spaced sub columns but the one on the far right does not want to agree. If I make the really long heading ...
3
votes
1answer
23 views

pgfkeys - storing today's date with pgfplotstablenew, pgfplotstablesave

I'm working on making a simple tool to generate burn down reports/track task progress; this is my first foray into more complicated table manipulation so there's probably something pretty basic I'm ...
4
votes
1answer
118 views

“Logarithmic scale” for negative values

I have the following MWE: \documentclass{standalone} \usepackage{pgfplots} \usepackage{pgfplotstable} \usepackage{filecontents} \pgfplotsset{compat=1.12} \begin{filecontents}{data.dat} 4 -1e4 4 -1e3 ...
2
votes
1answer
25 views

citations in pgfplotstable

So I'm calling data in to a pgfplotstable with \pgfplotstabletypeset[col sep=comma]{example.txt} which has been working fine, until I tried to include a citation in my example.txt file with \cite{...
6
votes
2answers
81 views

bold or higlight first row and column of tabe created from csv file

I'm using csvreader from csvsimple package to read csv data and create table from it. My goal is to bold or somehow highlight first row and first column. Here is my MWE: \documentclass{article} \...
1
vote
0answers
33 views

Linear regression with fixed point

I have a data set to which I want to add a trend line. For my system, there will always be a fixed point on (2, 0). I have the line representing this system, but currently I do not account for the ...
1
vote
0answers
35 views

Drawing multiple box plots from a file

I've got data in the following format n lw lq m uq uw 50 200 209 237 327 569 100 376 379 386 390 391 150 ... ... Where lw = lower whisker, lq = lower quartile, etc. I want to plot each box against ...
2
votes
1answer
23 views

pgfplotstable and longtable with caption is shown multiple times in tableslist

I'm visualizing a csv file using pgfplotstable and longtable as followed: \newcommand{\powerTable}[3]{ \pgfplotstabletypeset[ string type, col sep = comma, skip rows ...
5
votes
0answers
25 views

pgfplotstable show subset of rows?

I'm visualizing a csv with pgfplotstable as following: \pgfplotstabletypeset[ string type, col sep = comma, begin table=\begin{longtable}, end table=\end{longtable}, columns={{...
1
vote
0answers
43 views

PGPlots xtick label from a table

I am trying to load data from a table which looks like below and use the 'label' column for xticklabels. idx,label,value 1,20040101_20050108.rotation.summary, 19.470949839091155 2,20040101_20050115....
4
votes
1answer
44 views

Graph shifts position when adding plot

If I compile this code without the Gaussian function at the end everything is allright, but if I try with it the whole figure shifts to the right. In this example it is not a very big problem, but ...
2
votes
1answer
52 views

How to change the color background of a single cell in the last row

Using pgfplotstable, I want to color singular cells in the last row of an automatically created table based on csv-input. Since the length of the table differs, I need to color the last cell ...
0
votes
0answers
39 views

Longtabu in pgfplotstable from csv input with additional tikz lines

My question is based on this thread: Faulty table lines I have lots of csv-separated data e.g. in this format 11,22 33,44 55,66 ... and so on I'm creating tables automatically using the ...
0
votes
0answers
20 views

Multiple row in heading for tables

I have a problem formulating two rows in my heading of my table using pdfplotstable exporting csv file from excel. This is what i have: \usepackage{pgfplotstable} \documentclass[a4paper, 12pt]{book} ...
3
votes
1answer
34 views

Adapted table width to text using pgfplotstable and csv excel

I have a problem with forcing my table to the same width as the text. I export the csv (Excel) file to Latex using this approach, see code. Changing text-size in Excel works to a curtain "level", but ...
2
votes
1answer
27 views

pgfplotstable with .tsv file where the headers have underscores: How to avoid “Missing $ inserted”?

The file I want to show is a .tsv file that I cannot edit. It looks like this: up_gene up_chr up_strand up_Genome_pos APLP2 chr11 + 129991686 BACE2 chr21 + 42617990 BRDT chr1 + ...
3
votes
1answer
55 views

pgfplots - insufficient precision

I am having the following problem: Using pgfplots to plot some convergence graphs, I have to load a text file and do some computations. Most of the time everythings works just fine. But in some ...
0
votes
1answer
58 views

pgfplots: percentage in matrix plot

I'm trying to draw a matrix plot with the shown values in percentage. I already tried: nodes near coords = {\pgfmathprintnumber\pgfplotspointmeta\%} Unfortunately this didn't work out. Here is my ...
2
votes
1answer
33 views

Accessing Files with Spaces In Parent Directory Path

I'm having problems getting the pgfplotstable to compile because of issues with file path names containing spaces. I have read a bunch of other posts that say to just put quotes around things but none ...
0
votes
1answer
42 views

Change Default row separator in pgfplotstable / order of commands for each line

I edited the question and added a MWE. Please feel free to change tags or the title of the topic since I'm not sure how to categorize my problem. I'm using the tabu package and pgfplotstable for ...
1
vote
1answer
89 views

How to fill the parameters of `boxplot prepared` with data from table using PGFPlots?

I want to draw a boxplot using boxplot prepared@ Page 469 of pgfplots-manual; v1.13, with the values of lower whisker, lower quartile, median, higher quartile, and higher whisker from a data file. ...
0
votes
0answers
19 views

Longtable in pgfplotstable

I'm trying to get pgfplotstable in combination with a longtable to work. The data is read from a file "Errordata.dat". The file is saved as ANSI-formatted. 1,2,3,4,5,6,7,8,9 1,2,3,4,5,6,7,8,9 1,2,3,4,...
2
votes
0answers
69 views

longtable with pgfplotstable - adding predefined rows and breaking manually

Based on this link pgfplotstable; longtable with caption and repeating header I wrote this MWE: \documentclass{article} \usepackage{longtable} \usepackage{booktabs} \usepackage{multirow} \usepackage{...
2
votes
1answer
74 views

Plotting data series with pgfplots [duplicate]

I have a csv file index.dat with data Year,0-19 years,20-39 years,40-59 years,60-79 years,80-99 years,100 years+ 2000,100,100,100,100,100,100 2001,101,102,101,102,101,102 ... I am trying to plot ...
4
votes
1answer
53 views

pgfplotstableread{mydata.csv} VS table {mydata.csv} efficiency and capability for csv files pgfplots

I am trying to plot a very large .csv file with multiple columns using pgfplots. I want to use the first column for all my plots. My usual routine is to do something like: \addplot [solid] table [x=A,...
1
vote
1answer
31 views

pgfplots filter table with float content and conditions

I want to filter some data for a plot, and so far the best thing I found is this here. This is the relevant code from the mentioned question: \pgfplotsset{ discard if not and smaller/.style n ...
2
votes
0answers
48 views

Highlight first rows and first columns of a pgfplotstable

I'm trying to change the background color of the cells FOO and BAR and also the ones with the values (1 and 2) in the following MWE: \documentclass[12pt]{article} \usepackage[active,pdfpage,tightpage]...
5
votes
0answers
56 views

pgfplotstable longtabu repeating header and other options

I want to print a long table with pgfplotstable and long tabu. For some reason, with the following code, I do not get the header repeated on every page. I also want a \bottomrule and a caption on ...
1
vote
0answers
11 views

Current file relative paths and pgfplotstableread

For my latex documents I employ a structure like this: pictures doc1 doc2 ... To allow quick editing my picture folder contains a testfile. While I successfully use the import package to allow my ...
6
votes
1answer
94 views

Getting certain data out of .txt file

I'd like to use an external .txt file to provide a table in my LaTeX document with data. To achieve this I've taken into consideration the pgfplotstable package and the filecontents package. Both of ...
0
votes
0answers
15 views

pgfplotstable use cyclelist to color columns/header

Jake shows a beautiful example of presenting the same data in a table and a plot in this answer. However he manually sets the color for the bar graph(s) and the first table fields. I am wondering if ...
3
votes
1answer
54 views

Tikz pgf plot: cyclic shift of alphabetic labels on x axis

I have the following code to produce a plot \documentclass{standalone} \usepackage{tikz} \usepackage{pgfplots} \pgfplotstableread[row sep=\\,col sep=&]{ letter & freq \\ a & 11 \...
3
votes
1answer
84 views

! Missing # inserted in alignment preamble

I have a problem in compiling my tex file using nle.cls document class. The problem seems to be with package pgfplotstable. If I comment it our every thing works fine. The package disrupts the working ...
2
votes
1answer
46 views

Define and use column styles in pgfplotstable

Is it possible to define custom styles and use them to display columns? I have 10 columns, 3 of which are strings and the rest are floating point numbers with a series of options I've defined. I'd ...
2
votes
0answers
62 views

How to get rid of the following error with pgfplots?

When I am running the following code with data.txt file... \documentclass{standalone} \usepackage{tikz,pgfplots} \begin{document} \pgfplotstableread{data.txt}\Rtable \begin{...
6
votes
2answers
144 views

How to plot anomaly using two colors in a single plot with pgfplot?

I want to create a line plot using a table data included in the MWE. The thing is that, using this data, I want that the plot looks like the next figure: i.e., with different color areas for one ...