This is the initial release of my new GHCN software, titled UNHIDING THE DECLINE. It is designed to allow you to process large GHCN databases on a small computer with little memory, and make graphs very quickly.
The initial release is just for people who have python available. This includes any Mac or Linux user, and any Windows user who is willing to make the effort to install python3 and a gnu environment like cygwin or mingw. I will release a Windows exe file soon.
Open a terminal window
python3 -m pip install matplotlib
python3 -m pip uninstall numpy
python3 -m pip install numpy==1.12.1
Try this command to reproduce the plot above. It will take several minutes to bring the screen up, as it has to process the data
python3 ghcn.py US.txt summer text=”USHCN”
You can generate hundreds of different graph types very quickly by simply clicking on an X-axis option (left column) and Y-axis option (right column) . Click on the “Save Image” button to create a .png file, which is in the same directory you ran the ghcn.py script from. It also generates a csv file in that directory with all of the stats.
Other command line options include
- target_min=[temperature F] (used for stats)
- target_max=[temperature F] . (used for stats)
- required_range=[YYYY:YYYY] . ( station must have been active in both years)
The algorithm is very simple.
- Average all daily temperature records for one station for one month (that is how NOAA organizes them)
- Average all of the 1200 station averages for that month
- Repeat for all 12 months, and all years from 1895 to the present.
That is it. The algorithm is an improvement over my previous software, which lumped all daily data from all stations together per month. That unfairly weighted stations which reported more days relative to stations which reported fewer days.
To update the USHCN database, change the permissions on the bash get script, and run it “./get” . That will create a new US.txt file.
If you find any bugs, let me know! There may well be some. I just started this project last weekend. I’ve been at this for 12 straight hours and need to get out on my bike!