modes.tex
\documentclass[border=10pt]{standalone}
\usepackage{pgfplots, tikz, amsmath}
\usepackage{filecontents}
\usepgfplotslibrary{colorbrewer}
\usepgfplotslibrary{fillbetween, external}
\pgfplotsset{compat=1.8}
\begin{document}
\begin{tikzpicture}
\begin{axis}[
ylabel=$|\hat{r}{(k, t)}|^2$,
xlabel= $t/T$,
width = 6cm,
height = 4.5cm,
xmin=0,
xmax=1,
cycle list name=Paired-10,
scaled y ticks=base 10:-3,
minor tick style={draw=none}
]
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode0.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode0.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode0.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode1.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode1.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode1.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode2.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode2.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode2.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode3.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode3.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode3.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode4.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode4.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode4.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
\addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode5.txt};
\addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode5.txt};
\addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode5.txt};
\addplot [fill=black!10] fill between[of=upper and lower];
% \addplot +[thick, mark options={fill=black,scale=0.5}] table[x=x,y=y] {./data/mode6.txt};
% \addplot [name path=upper,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}+\thisrow{err}] {./data/mode6.txt};
% \addplot [name path=lower,draw=none] table[mark options={fill=black,scale=2}, x=x,y expr=\thisrow{y}-\thisrow{err}] {./data/mode6.txt};
% \addplot [fill=black!10] fill between[of=upper and lower];
\end{axis}
\end{tikzpicture}
\end{document}