# Soft clip defined by domain fails in fill between for one of tables

I cannot understand why figure (a) does not display the filled region, while (b) does.

PGF reports the following warning:

Package pgf Warning: fill between skipped: the first input path is empty. on input line 20.

Here is my code:

\documentclass{article}

\usepackage[labelformat=simple]{subcaption}
\usepackage{pgfplots}
\pgfplotsset{width=7cm,compat=1.14}
\usepgfplotslibrary{fillbetween}

\begin{document}

\begin{figure}
\centering
\begin{subfigure}[t]{0.5\textwidth}
\begin{tikzpicture}
\begin{axis}[try min ticks=6]
\addplot[orange] fill between[of=A and B, soft clip={domain=0:10}];
\end{axis}
\end{tikzpicture}
\caption{}
\end{subfigure}%
~~%
\begin{subfigure}[t]{0.5\textwidth}
\begin{tikzpicture}[yscale=1.0, xscale=1.0]
\begin{axis}[try min ticks=6]
\addplot[orange] fill between[of=A and B, soft clip={domain=0:10}];
\end{axis}
\end{tikzpicture}
\caption{}
\end{subfigure}
\end{figure}

\end{document}


• tab3.dat etc. is missing -- apart from that, nice MWE :) May 10 '17 at 21:08
• @Dr.ManuelKuehner, why are data files missing:)? I linked them at the end. May 10 '17 at 21:59
• Missed that :). May 10 '17 at 22:03

I have no idea why, but it seems the soft clip is sensitive to the scaling (or something). For example, if you remove the first 70 data points of tab1.dat, or set xmin=-28, it works fine.

None of those are solutions of course, but you can increase the width to 8cm. That works fine here at least.

\documentclass[border=5mm]{standalone}
\usepackage{pgfplots}
\pgfplotsset{width=8cm,compat=1.14} %% <-- 8cm here
\usepgfplotslibrary{fillbetween}

\begin{document}

\begin{tikzpicture}
\begin{axis}[try min ticks=6]
\addplot[orange] fill between[of=A and B, soft clip={domain=0:10}];
\end{axis}
\end{tikzpicture}
\begin{tikzpicture}[yscale=1.0, xscale=1.0]
\begin{axis}[try min ticks=6]