[pstricks] fileplot problem

Herbert Voss Herbert.Voss at alumni.TU-Berlin.DE
Fri Feb 4 15:39:24 CET 2005


Aydin Ustun wrote:
> I am trying to plot a time series between 1980-2005 years from a 
> external file. But, the output does not appear in the axes-frame.

choose listplot, then it is easier to modify the values ...

Herbert


\documentclass[12pt,a4paper]{article}

\begin{filecontents}{data2.dat}
1980.0 1447.89
1981.1 1207.96
1982.2 1351.99
1983.3 1540.16
1984.3 1729.44
1985.4 1718.2
1986.5 1729.67
1987.6 1911.74
1988.7 1767.24
1989.8 1790.97
1990.8 1730.78
1991.9 1825.62
1992.0 1866.13
1993.1 1284.53
1994.2 1719.38
1995.3 1712.79
1996.3 1891.32
1997.4 1828.84
1998.5 1887.23
1999.6 1843.91
2000.7 1909.15
2001.8 1872.08
2002.8 1937.21
2003.9 2074.47
2004.0 1651.92
2004.9 1408.19
\end{filecontents}

\usepackage{pstricks}
\usepackage{pstricks-add}
\begin{document}

\pstScalePoints(1,1){ 1980 sub }{}% for both images
\readdata{\data}{data2.dat}

\psset{xAxisLabel=,yAxisLabel=}
\psgraph[axesstyle=frame,Ox=1980,Dx=5,Dy=500,subticks=5](0,0)(25,2200){12cm}{7cm}
   \listplot[linewidth=3pt,linecolor=blue]{\data}
\endpsgraph

\vfill
\psset{xunit=5mm,yunit=0.003}
\begin{pspicture}(0,0)(25,2200)
   \psaxes[axesstyle=frame,Ox=1980,Dx=5,Dy=500](0,0)(25,2200)
   \listplot[linewidth=3pt,linecolor=blue]{\data}
\end{pspicture}

\end{document}



-- 
http://TeXnik.de/
http://PSTricks.de/
ftp://ftp.dante.de/tex-archive/info/math/voss/Voss-Mathmode.pdf
http://www.dante.de/faq/de-tex-faq/
http://www.tex.ac.uk/cgi-bin/texfaq2html?introduction=yes




More information about the PSTricks mailing list