[pstricks] Reading data with raw postscript

Poul Riis Poul.Riis at skolekom.dk
Sun Mar 30 22:02:11 CEST 2008

How can I read data from a file with raw postscript commands (see
not-working-example below)?
I guess it has something to do with \ but I also tried to replace it with

Poul Riis

\def\psReadfile{\pst at object{psReadfile}}
\def\psReadfile at i#1#2{%File name, number of columbs
   \begin at SpecialObj
   \addto at pscode{
/inputdatafile (#1) (r) file def
%%%%%%%%%%%%%%%%%  read data commands, for instance from
inputdatafile closefile
   \end at SpecialObj}

\psaxes[ticksize=-3pt 0]{->}(0,0)(-2,-2)(10,10)
   \psReadfile{D:\miktex\filereadertest.dat}{2}%File name, number of

-------------- next part --------------
A non-text attachment was scrubbed...
Name: filereadertest.dat
Type: application/octet-stream
Size: 4916 bytes
Desc: not available
Url : http://tug.org/pipermail/pstricks/attachments/20080330/0dc9fd9a/attachment.obj 

More information about the PSTricks mailing list