[pstricks] Minipage and Pstricks -> xAxis undefined.
Patrick Drechsler
patrick at pdrechsler.de
Mon Nov 12 15:46:16 CET 2007
"Hans Henrik Sievertsen" <hhsievertsen at gmail.com> writes:
> 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.
Can't help with this. But your example produces two y axes, doesn't it?
> Here is an example:
>
[...]
> \psset{xunit=0.75 mm}
> \pspicture(0,0)(160,6)
^^ This figure is too wide for the other picture to fit side by side:
160*0.75=12cm.
> The first error message reads:
> ! keyval: xAxis undefined.
> \KV at error #1->....
Did you load the package pstricks-add?
Some ideas:
--8<---------------cut here---------------start------------->8---
\documentclass{article}
\usepackage{pstricks,pstricks-add}
\usepackage{subfig}
\begin{document}
\begin{figure}[h]
\subfloat[][Kaplan-Meier Hazard rates from open unemployment into ALMP.]{%
%% I don't have the data...
% \readdata{\data}{KMALMP.txt}
\framebox{% for debugging
% \psset{xunit=0.75mm}%
\psset{xunit=0.4mm}%
\begin{pspicture}(0,-0.5)(180,6.5)%
\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}%
\end{pspicture}%
}%
}\quad%
\subfloat[][Unemployment in 2005.]{%
%% I don't have the data...
% \readdata{\dataa}{KMEMPLNONPART.txt}
% \readdata{\datab}{KMEMPLPART.txt}
\framebox{% for debugging
\psset{xunit=0.375 mm}%
\begin{pspicture}(0,-0.5)(180,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}%
\end{pspicture}%
}%
}%
\end{figure}
\end{document}
--8<---------------cut here---------------end--------------->8---
HTH
Patrick
--
I never used a logarithm in my life, and could not undertake to
extract the square root of four without misgivings.
(Georg Bernhard Shaw)
More information about the PSTricks
mailing list