############################################################### # Instruction to convert ATCA files from MIRIAD to CASA ############################################################### # MIRIAD ############################################################### !/usr/bin sh # Load data into miriad ATLOD in="*.C2046" out="out.uv" options=opcorr,birdie,noauto,rfiflag # Initial flagging (flag shadowing, bad timing, sick antennas...): UVFLAG vis="pica.uv" select="shadow(22)" flagval=flag # Index and split: UVINDEX vis="out.uv" UVSPLIT vis="out.uv" ############## # Further flagging if needed on single targets # Calibration according to the needed scheme ############## # Convert to uvfits all the files in the data_folder that need to be used for following analysis. # Add to FITS the options=nocal,nopol,nopass in case you are converting data with no calibration applied for file in `cat data_folder' do FITS in=$file op=uvout out=$file.fits stokes=xx,yy,xy,yx options=nocal,nopol,nopass done ############################################################### # CASA ############################################################### # Convert from uvfits to MS. IMPORTUVFITS(fitsfile='$file.fits', vis='$filems', antnamescheme='old', async='False') # Now you can deal with the $filems as a common measurement set. Verify your conversion with LISTOBS(vis='$filems', verbose=True) PLOTMS(choose your parameters to see what is the status of bandpass, phase, amplitude) CLEAN(to image your target) # If you have more than one target (i.e. source+calibrators) and you want them in the same ms or # if you deal with a mosaic and you want to put all the pointings in the same ms (a.g. to image the whole mosaic area) # concatenate the ms to a 'unique_ms' CONCAT(vis=['point1','point2',...], concatvis='unique_ms') # Again check the unique_ms with LISTOBS(vis='unique_ms', verbose=True) CLEAN(to image your target, use imagermode='mosaic' if needed)