#! /bin/sh wait=$1 file=$2 #---------------------------------------------------------- sm -s < #-----------------------do the same thing using a loop set dimen(w)=dimen(x) do i=0,dimen(x)-1,1 { set w[\$i] = x[\$i]**2 + sqrt(y[\$i]) echo \$(w[\$i]) } #-----------------------make plot erase limits x y expand 1.1 box expand 1 ptype 8 3 points x y ltype 0 connect x y expand 1.5 xlabel x ylabel y expand 1 #---------------------------------------------------------- if ($wait) {!sleep $wait} else {hardcopy} FIN #----------------------------------------------------------