Invoke ASTQDP on a spectrum, sending the output to the postscript device, and retain the QDP file.
% astqdp -k spectrum /ps PLT> fit lin ... ... more QDP commands ... PLT> quit