xy2sky (wcstools)

This routine takes a file of input X,Y for an image with valid WCS installed in the FITS header, and predicts the Ra,Dec (in sexigecimal format) for those XY positions. In the example below, the image is named "dss.fits" and we process the input X,Y coordinates in the fiale named :image2.XY. All of the Ra,Dec values are directed to the file named "image2.RaDec":

 

%  xy2sky dss.fits @image2.XY > image2.RaDec  

To process X,Y directly:
%  xy2sky n3379_wcs.fits 974 1078 
10:47:49.537 +12:35:22.18 J2000  974.000 1078.000 
  




A more refined example (Oct2014)

I have been developing more simplified ways to get results from ds9 and mido runs into easily displayed formats. Moreover, I want to be able to compute and install RA,DEC from X,Y data derived in various ways. The routine midodata gives me a way to make very simple X,Y data files that can be passed through xy2sky in order to compute equatorial coordinates. Here are two examples, one using an mage that has WCS in the header, and one that does NOT have WCS.

  
% xy2sky -d n3379_wcs.fits @midodata.XY
161.95676  12.58183 J2000  973.190 1057.630 
161.96763  12.55516 J2000  945.330  986.560 
162.02885  12.59415 J2000  785.950 1089.420 
161.87096  12.60713 J2000 1195.480 1126.080 

% xy2sky -d n3379.fits @midodata.XY
n3379.fits: No WCS for file, cannot compute image size



Back to SCO CODES page