14.3) Exercise 38 - Bradford Weather
For this exercise, you’ll need to download the following file:
bradforddata.txt
This file (bradforddata.txt) contains data from the Bradford weather station. It consists of:
- Mean daily maximum temperature (tmax)
- Mean daily minimum temperature (tmin)
- Days of air frost (af)
- Total rainfall (rain)
- Total sunshine duration (sun)
Missing data (more than two days missing in a month) have been indicated by "---".
- Read in weather data from Bradford station. Skip the header rows and specify the string used to represent missing values.
- Calculate the mean temperature for each month (tmean) as the average of tmax and tmin.
Solution: np_exercise_bradford_data.py
To go further: write the monthly mean temperature of Bradford to a file.