project MK6: Post processing radio astronomy data; plot
The data you have captured with CFRAD2.exe or other programs can be postprocessed with python or excel.
First we will process it with excel to give you an idea of the procedure.
Excel post processing
In the capture example we have given 2 result files; nrad29 is was captured as the dish was pointed to the source, and nrad180 was taken 12 hours later, when not pointed to the milkey-way as a reference. Two example data files measured with an 80cm dish can be downloaded from here;
To have a look at it you can open it in an editor; we use free "editpad light". The 2048 values are the bin values of successive frequency bands. Also you see that the decimal seperator is a dot. Excel in some countries wants to see comma's, so to change that go to edit, select all, now go to search, and click prepare to search. In the left bottom corner two windows are visible; put in a dot left and a comma right. Now go in the search tab to replace all; done. The list is still highlighted, now; rightclick copy. Startup excel and click on the left most colomn and right click paste. Do the same for the second file; the reference file; nrad180.
If you insert a graph now and plot the two colomns you will get a passband curve. We can correct that by making a third colomn where we divide colomn A/B. Next, in colomn C we amplify the graph and subtract a constant value to bring it into the window. Now you can insert a graph, and it would be similar to the example.
Fig.1 - Excel result.
Fig.2 - Python plot2 band pass.
And some details where you can see that the anti peak function is working.
Fig.3 - Python plot2 peak removal.
This is the function we will use later to correct the received signals with.
Fig.4 - Python plot2 band pass correction.
You can zoom in on any part of the graph by selecting the fifth icon from the left.
When you are done, you can click the X in the right upper corner. The script continues the program and halts to display the "selected 5 minute" measurement.
It gives thesame result as the A/B funtion in excel. Now we see the actual hydrogen line curve.
Fig.5 - Python plot2 select curve 29.
Fig.6 - Python plot2 selected curve 29 detail.
Click on X to proceed.
Fig.7 - Python plot2 final20b.
Fig.8 - Python plot2 raw detail.
Click on X to proceed.
Fig.9 - Python plot2 final20 detail.
The full 24 hour session
The full 24 hour data (289 data flies) can be downloaded from here; cfrad288.zip Also the python sript is added into the zip file. Python is a free platform used in scientic and universities. It is fast and has the feel of old "Basic". The version used by us is Python-xy and can be found in the downloads tab. Included is the an editor called "Spider".
In the 'Spider' editor go to the folder with the unzipped files and , open the file cfrad288.py, and run it. The reference for this 24 hour run is taken from the quiet part of the scan, this is not what we normal do, because everywhere there are hydrogen background signals, but for the moment this is easy. So the the scans 180 to 190 are taken as "zero" reference. The mean value of these scans are taken, which gives a smooth line like;
Fig.8 - 288 band pass curve detail.
In another project we can also show the use of a polynome with multi-coefficients to fit the curve. making it even more smooth.
For now we use this curve to inverse multiply the rest of the measured files with. The script continues when the top right X is pressed. Next the selected curve is shown. Here we can judge the script lines we think of and we do not have to wait for the processing of all the files.
Fig.8 - 288 selected file detail 01.
Fig.8 - 288 selected file detail 02.
If done press X again; the complete 288 files are now being processed.
Fig.8 - 288 all scans.
Fig.8 - 288 detail 01.
Fig.8 - 288d 02.
Fig.8 - 288 detail 03.
Michiel Klaassen nov-2014