I want to make a figure with several plots with error bars. Each curve has 1100 points. I want to draw only a few (5) error bars to increase legibility. For the same reason, I would like to have each set of error bars shifted of a different interval. Something like :
plot 1 : error bars at 0, 250, 500, 750, 1000 ; plot 2 : error bars at 10, 260, 510, 760, 1010 ; plot 3 : error bars at 20, 270, 520 ,770, 1020 ; etc.
My current attempt is :
\pgfplotsset{err/.style={each nth point={250},forget plot,draw=none}}
\pgfplotsset{errp/.style={err, error bars/.cd,y dir=plus, y explicit}}
\pgfplotsset{errm/.style={err, error bars/.cd,y dir=minus, y explicit}}
% plot 1
\addplot+[errm] table[x index=0,y index=1, y error index=2}]{\table};
\addplot+[errp] table[x index=0,y index=1, y error index=3}]{\table};
\addplot table[x index=0,y index=1]{\table};
% plot 2
\addplot+[skip coords between index={0}{10}, errm] table[x index=0,y index=4, y error index=5}]{\table};
\addplot+[skip coords between index={0}{10}, errp] table[x index=0,y index=4, y error index=6}]{\table};
\addplot table[x index=0,y index=4]{\table};
% plot 3
\addplot+[skip coords between index={0}{20}, errm] table[x index=0,y index=7, y error index=8}]{\table};
\addplot+[skip coords between index={0}{20}, errp] table[x index=0,y index7, y error index=9}]{\table};
\addplot table[x index=0,y index=7]{\table};
% etc.
The each nth point={250} acts as I want but skip coords between
index={0}{20} does not (it only suppress the first error bar).
In addition, compilation time is tremendous and I wonder if changing somehow my method could diminish it (I already use externalisation). My other attempt was to generate a table for the errors containing only the relevant data and plot them all. This is somewhat more cumbersome because it requires to go back to the generation of data each time one wants to alter how the plot looks.
To sum up:
- how to introduce the skip ?
- Is there a more concise and efficient code to do that ?
Some data:
First column is abscissa. Then 3 column of data. Then 3 column minus error. Then 3 column plus error.
The example:
expl.tex is the main, graph.tex is the figure.

\documentclass)? Coming up with dummy data and a framework document is always the dullest part of answering a question, so it would be great if not every person trying to come up with an answer would have to go through that. – Jake Apr 25 '12 at 08:18