So I've decided to clean my code for the many plots.
I've basically taken out all the plot data into separate files using
\def\plotname{
x1 y1
}
Then I use \input{data.txt}
to load all the plotting data at once and then
\begin{NumericDataPlot}{\textwidth}{6cm}
\newpsstyle{MyLineB}{linecolor=blue, linestyle=none,showpoints=true,dotsize=1pt}
\listplot[style=MyLineB]{\plotname}
\end{NumericDataPlot}
So far, so good. Most plots work as expected. However it turns out there is some issue with some \def
names.
For instance, using \muIPS
leads to the following error
! Use of \muIPS doesn't match its definition.\addto@pscode ...ef \pst@code {\pst@code #1\space} \listplot[style=MyLineB]{\muIPS}
But when I change the name to \muips
it compiles just fine.
So to sum up, LaTeX seems to be very idiosyncratic about the def name it allows. Please note that the names were working fine before I used nested input files...
EDITED FOR EXPLANATION :
One of the other names was \def\muIPS-U
and it wasn't used.
So when I changed to \muips
, it had no confusion about the definition to use. Turns out, you can't use - character in the defname
? What other characters are forbidden?
\muIPS
?\def\muIPS-U
is not possible in this way. Use only characters or\csname muIPS-U\endcsname
.