[pstricks] Minipage and Pstricks -> xAxis undefined.

Hans Henrik Sievertsen hhsievertsen at gmail.com
Mon Nov 12 13:48:48 CET 2007


Hi,
Im quite new to pstricks, but already fascinated. I'm very thankful for the
great package and documentation. But I have a small problem, and I can't
find any solution for it in the documentation or mailing-list.

I have to pstricks figures, that I want to place next to each other. For the
moment I'm using \minipage, and it is working all fine. But I find, that som
features from \pstricks are not possible in the \minipage environment. F.
ex. creating two y-axes or using "nEnd" in a listplot.

Is it possible to get the full functionality of pstricks in \minipage? Or
can I use another set up? I have tried subfloat, with the same setup.

Here is an example:

\begin{figure}[h]
 \hfill
 \begin{minipage}[t]{.45\textwidth}
\readdata{\data}{KMALMP.txt}
\psset{xunit=0.75 mm}
\pspicture(0,0)(160,6)
  \psaxes[Dx=10,dx=0.75 cm,Ox=0,Dy=0.005
,dy=1cm,tickstyle=below,ticksize=5pt](20,0.25)(160,6.25)
  \psaxes[xAxis=false,tickstyle=top,Dy=0.005
,dy=1cm,tickstyle=below,ticksize=5pt](160,0.25)(160,6.25)
  \pstScalePoints(1,200){20 add}{0.00125 add}
  \listplot[linecolor=black,linewidth=1pt, nEnd=140]{\data}
\endpspicture
\caption{Kaplan-Meier Hazard rates from open unemployment into ALMP}
 \end{minipage}
 \hfill
 \begin{minipage}[t]{.45\textwidth}
\readdata{\dataa}{KMEMPLNONPART.txt}
\readdata{\datab}{KMEMPLPART.txt}
\psset{xunit=0.375 mm}
\pspicture(0,0)(160,8)
  \psaxes[Dx=10,dx=0.375 cm,Ox=0,Dy=0.01
,dy=1cm,tickstyle=below,ticksize=5pt](20,1)(160,8)
  \psaxes[xAxis=false,tickstyle=top,Dy=0.01
,dy=1cm,tickstyle=below,ticksize=-5pt](160,1)(160,8)
  \pstScalePoints(1,100){20 add}{0.01 add}
  \listplot[linecolor=black,linewidth=1pt, nEnd=140]{\dataa}
  \listplot[linestyle=dashed,linewidth=1pt, nEnd=140]{\datab}
  \psline[linestyle=dashed,linewidth=1pt](50,0.25)(70,0.25)
  \rput(60,0){Participants}
  \psline[linewidth=1pt](100,0.25)(120,0.25)
  \rput(110,0){Non-participants}  \label{int}
  \caption{Unemployment in 2005}
 \end{minipage}
 \hfill
\end{figure}


The first error message reads:
! keyval: xAxis undefined.
\KV at error #1->....

When I place the two figures above each others as separate figures,
everything works fine.


Can anyone help?
Thanks in advance.

Hans H. Sievertsen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://tug.org/pipermail/pstricks/attachments/20071112/41d8ce14/attachment.html 


More information about the PSTricks mailing list