Filter METAR code for precipitation by wind direction and sum it?

I have 20 years of METAR surface weather observation data (.txt) to filter (24+ obs per day) for three locations. I am mainly interested in the "7" group (70000 in this example) which indicates hundredths of inches of precipitation. Below is an example line, with the 7 group in the KDFW 251153Z line.
KDFW 251209Z 06003KT 5SM -DZ BR OVC007 01/M01 A3026 RMK AO2 P0000 T00061006 $
KDFW 251153Z 00000KT 5SM -DZ BR SCT005 OVC010 01/M01 A3027 RMK AO2 SLP252 P0000 60048 70050 I6000 T00061011 10006 20000 55014 $
KDFW 251128Z 00000KT 8SM -RA FEW005 BKN009 OVC050 01/M01 A3027 RMK AO2 P0000 T00061006 $
In priority order 1. Add all the "0000" portions of the 7 group to a running sum. (needed for term project) 2. I want to bin the sum of the 0000 group into bins by wind direction every 90 degrees (000-080, 090-170, 180-260, 270-350. (00000KT is wind in the above example. DDDSSKT format -- DDD direction in degrees, SS speed in knots).
other priority optional 3. If possible, I want to identify any cloud below 15000 feet (150 in METAR) and sum the coverage in eighths of the sky. (SKC or CLR = 0, FEW = 1-2, SCT = 3-4, BKN = 5-7, OVC = 8)
Any help or links to similar code would be greatly appreciated. -Nate

Answers (0)

Categories

Find more on Weather and Atmospheric Science in Help Center and File Exchange

Asked:

on 26 Nov 2013

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!