[pstricks] 2d-plotting problem
Michael Sharpe
mchl.sharpe at gmail.com
Wed Oct 7 05:02:02 CEST 2009
On Oct 6, 2009, at 7:09 PM, Bob Wang wrote:
> Hi there,
>
> I've recently spend sometime attempting to figure how to plot a good
> 2d plot from .csv file attached. But encountered many difficulties.
> The csv file is from oscilloscope data giving the voltage levels
> versus time (2000 points).
> • I got an error saying arithmetic overflow (this is because my x-
> axis number is incrementing really small steps I think)
> • I tried modifying the x axis numbers but it produced a large
> graph which I can't scale down. (I really need the x-axis unchanged
> really, so this is not an alternative solution)
> Bob
>
Your limited time resolution won't allow for much detail, but here's a
way to get a little something. (Note---you were not using any features
of pst-2dplot.)
\documentclass{article}
\usepackage{pstricks}
\usepackage{pst-plot,pstricks-add}
\begin{document}
\psset{yunit=2mm,xunit=5mm}
\begin{pspicture}(-1,-1)(21,41)
\psaxes[axesstyle=axes,Dx=2,Dy=10]{->}(21,41)
\readdata{\mydata}{data9.csv}
\pstScalePoints(1,1){.225576 sub 1000000 mul}{}% time values now run 0
to 20
\listplot[plotstyle=line]{\mydata}
\end{pspicture}
\end{document}
Michael
More information about the PSTricks
mailing list