Graphics, Figures & Tablespstricks-add | Axis Labels seemingly in Math Mode

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
User avatar
svend_tveskaeg
Posts: 478
Joined: Sun Jul 12, 2009 5:31 am

pstricks-add | Axis Labels seemingly in Math Mode

Post by svend_tveskaeg »

Hi all.

In the document below, the labels, set with xLabels, are in math mode. Is there an error in pstricks-add or have I made some simple mistake, which I cannot spot?

Code: Select all

\documentclass{article}
\usepackage{pstricks-add}

\begin{document}

\begin{figure}
\def\bredde{0.7 }
 \centering
  \psset{
    xunit=0.7cm,
    yunit=0.05cm
  }
   \begin{pspicture}(15,240)
    \psaxes[
      xLabels={
       ,Nord,
       ,Syd,
       ,Midt-Vest,
       ,Fyn,
       ,Bornholm,
       ,Lorry,
      },
      xLabelsRot=90,
      Dy=2,
      dy=20,
      ticks=y,
      ylabelFactor={\cdot 10^4}
    ]{->}(0,0)(12,230)[Tv-stationer,0][Seere,90]
    \multido{\i=20+20}{11}{%
      \psline[linestyle=dotted](0,\i)(12,\i)
    }
  \pspolygon[fillstyle=solid,fillcolor=red!45]%
    (!2 3 mul 1 sub \bredde 2 div sub 0)%
    (!2 3 mul 1 sub \bredde 2 div sub 107)%
    (!2 3 mul 1 sub \bredde 2 div add 107)%
    (!2 3 mul 1 sub \bredde 2 div add 0)
  \rput(!2 3 mul 1 sub 107 5 add){\scriptsize{107\,000}}
  \rput{90}(!2 3 mul 1 sub 107 2 div){\scriptsize{12{,}2\,\%}}%
   \end{pspicture}
\end{figure}

\end{document}
Thank you in advance!
``In the game of chess, you can never let your adversary see your pieces.''
-- Zapp Brannigan, Futurama (season 1, episode 4)

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Post Reply