This OTW script use the solution from wcs0 to derive the image rotation angle.
% rotafind.sh wcs_setup.out 1.356678 arg1 = name of input [name,x,y,r,d] file (e.g. wcs_setup.out) arg2 = plate scale in arcsec/pixel (from psfind.sh) A typical run in a script (like wcs1): # Derive the rotation angle rotafind.sh $2 $pscale > WCS1_Info.CROTA read theta errtheta theta_comment < WCS1_Info.CROTAThe rotation angle and mean error (in degrees) are written to standard out. In a script these results are typically directed to an output file (as shown above)