Due Friday, July 30th, at the start of class.
The purpose of this four-part project is to compare weather forecasts against actual weather observations. In this first part, you will write a script that downloads the current weather forecast and parses it.
Every day, sometimes several times during the day, there is a text weather forecast for Madison posted at the following URL:
The forecast is generally for the next several days. But, we are simply interested in the forecast for today. Here is a sample of the actual HTML that includes the forecast for one day:
<TD> <H1>Madison Forecast</H1> Local Madison Forecast 300 AM CDT THU JUL 29 2010 <br><br><font size=+1><B>TODAY...</B></font>SUNNY. HIGHS IN THE LOWER 80S. NORTHWEST WINDS UP TO 5 MPH. <br><br><font size=+1><B>TONIGHT...</B></font>PARTLY CLOUDY. LOWS AROUND 60. NORTHWEST WINDS UP TO 5 MPH THROUGH AROUND MIDNIGHT BECOMING CALM.
Note: The sample above does not include most of the actual HTML page downloaded from the URL above. There are many more lines in the real file!
The goal for today is to parse enough of the downloaded forecast to get a Unix time for the forecast time, and actual numeric forecast predictions for the high and low temperatures.
For today, your script must:
Do the work yourself, consulting reasonable reference materials as needed; any reference material that gives you a complete or nearly complete solution to this problem or a similar one is not OK to use. Asking the instructors for help is OK, asking other students for help is not.
A printout of your script on a single sheet of paper. Be sure to put your own name in the initial comment block of the code. Identifying your work is important, or you may not receive appropriate credit.