Sunday, August 31, 2008

Gustav: Bush visits HQ/Bee sting on the behind

I'm at FEMA Headquarters. We're all preparing for the long haul, getting in additional personnel, calling people off of their leave, having meetings... There is still hope that this thing could weaken a lot before hitting, but we're trying to be realistic. It could still be really bad, and no one wants to be caught off-guard (again).

In that spirit, the President came to headquarters. I really don't have much to say about that. It certainly was the right thing for him to do.

This morning I went out and did 100 burpees in 14:25. It kicked my butt. About halfway through a bee came and stung me on the behind. I'm not kidding. Actually, it wasn't as bad as I remembered bee stings to be. It's bothering me now, though.

Saturday, August 30, 2008

Gustav hits Cat 4

Gustav was upgraded to Category 4 just a couple of hours ago, and it looks like nothing is in its way except a warm Gulf of Mexico. I think about the folks in Cuba and shudder.

It is so odd to be here at FEMA Headquarters, seeing the sun shine. I keep thinking I should remember this moment. All is uncertain right now-- but certainty has a way of creeping up on you. Soon we will know just how bad (or not) Gustav is going to be.

My friend Ruth is in town with her husband. We had to cancel getting together because I'll be working (who knows how long?). She said she'd be praying for the people of the gulf coast. I just thought, we're going to be working our tails off to help those people. A little prayer sure couldn't hurt.

Gustav, Hanna, and the view from FEMA Headquarters

FEMA headquarters is pretty alive today. That's good; I'd hate to think we'd all be taking a three day weekend with Gustav breathing down the Gulf Coast's neck. There is a palpable sensation here that the three year anniversary of Katrina was just yesterday, two potential threats are too close for comfort, and we may have to do our jobs.

Oddly enough, three years ago today, Sonia, Daniel, and I were in Lafayette with Beau, Elena, and Luis (see http://timothychenallen.blogspot.com/2005/10/how-we-evacuated-from-hurricane-katrina.html). Right now, the forecast has Gustav rolling right into Lafayette.

Just to get my mind off of things, I went out for a 70 minute run this morning. You know, I really hope nothing happens. But the chances of that are really getting very slim.

Wednesday, August 27, 2008

Perl: Make KML from NOAA Forecast

I wanted a simple way to make GoogleMaps KML to show forecasted storm tracks. The forcasted storm tracks can be downloaded from the National Hurricane Center and generally look like this. This is today's forecast for TS Gustav:


INITIAL 27/1500Z 18.8N 74.0W 50 KT
12HR VT 28/0000Z 19.0N 74.8W 55 KT
24HR VT 28/1200Z 19.2N 76.0W 60 KT
36HR VT 29/0000Z 19.3N 77.5W 70 KT
48HR VT 29/1200Z 19.9N 79.4W 80 KT
72HR VT 30/1200Z 21.5N 83.0W 100 KT
96HR VT 31/1200Z 24.5N 86.0W 100 KT
120HR VT 01/1200Z 28.5N 88.5W 100 KT

So I wrote a Perl program to translate that into a KML file. The program looks like this:

use strict;
#Get the storm name from the user
print "Storm Name? ";
my $storm = <STDIN>;
chomp($storm);

#Print out the KML header
print << "STARTLINE";
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://earth.google.com/kml/2.2">
<Document>
<name>$storm</name>
<open>1</open>
<description>NOAA $storm track</description>
<Folder>
<name>Placemarks</name>
<description>$storm</description>
<Placemark>
<name>$storm</name>
<LineString>
<tessellate>1</tessellate>
<coordinates>
STARTLINE

# Build kml stanzas for the line and forecast markers
my $line = "";
my $points = "";
while(<DATA>) {
chomp;
if (m/^ *(INITIAL|\d+HR VT) +(\d+\/\d{4}Z) (\d+\.\d+)N +(\d+.\d+)W +(.*)$/) {
$line .= "-$4, $3\n";
$points .= << "HERE"
<Placemark>
<name>$1, $2, $5</name>
<Point>
<coordinates>-$4, $3</coordinates>
</Point>
</Placemark>
HERE
}
}
# Print everything out, including the end of the kml
print $line;
print << "FINISHLINE";
</coordinates>
</LineString>
</Placemark>
FINISHLINE
print $points;
print << "FINISHPOINTS";
</Folder>
</Document>
</kml>
FINISHPOINTS
__DATA__
INITIAL 27/1500Z 18.8N 74.0W 50 KT
12HR VT 28/0000Z 19.0N 74.8W 55 KT
24HR VT 28/1200Z 19.2N 76.0W 60 KT
36HR VT 29/0000Z 19.3N 77.5W 70 KT
48HR VT 29/1200Z 19.9N 79.4W 80 KT
72HR VT 30/1200Z 21.5N 83.0W 100 KT
96HR VT 31/1200Z 24.5N 86.0W 100 KT
120HR VT 01/1200Z 28.5N 88.5W 100 KT


As you can see, I copy and paste the NOAA storm forecast into the program. The resulting GoogleMap looks like this:

View Hurricane Gustav Forecast in a larger map
Oh my, that looks uncomfortable for New Orleans. Keep your fingers crossed.

Tuesday, August 26, 2008

Hurricane Gustav: Yikes!

I've been looking at Hurricane Gustav. Right now it still hasn't made landfall in Hispaniola, but it's already made Category 1 and has a whole big, hot Gulf of Mexico in front of it. Given how flat-footed Katrina caught me, I just thought... what if?


So I'll be keeping an eye on this one. The gulf of Mexico is hot, right at 86F (you can look at this at http://www.nodc.noaa.gov/dsdt/cwtg/egof_tmap.html). Let's hope for the best! But one piece of advice: if you have to evacuate, don't just bring an extra shirt and your guitar like I did.

Monday, August 25, 2008

Vibram FiveFingers: Nice First Run!


Yesterday Afternoon I went out and bought a pair of Vibram FiveFingers. I reckoned on trying them out on Tuesday, as today I was set to just do some burpees. As it turns out, I finished those and had some time before I had to be anywhere, so I decided to go on a quick five minute jog just to see how they were.

They were so nice that I ended up going out for 25 minutes. I ran on the bike path in Rock Creek Parkway, across a couple of fields, through some rocky areas, etc. My feet felt fine-- the only time I was a little uncomfortable was when I ran over some rocks and a rock got me right in the arch. It was not a big deal.

Surprisingly, they felt just fine on pavement. This may be due to the fact that I ran in Nike Frees for most of the last couple of years. I've been trying to find some running shoes that would not protect my feet too much. I think that for a while there, shoes got progressively more and more protective. As a result, I think our feet have gotten dumber and dumber. They can no longer fend for themselves. So I got some running sandles (which were cool, but had a tendancy to get rocks in under my heel) then the Nike Frees (which were really great, no complaints).

What was different about the Vibram FiveFingers was having my toes separated out there. I found myself wiggling my toes between steps, spreading my toes way out. My little toe on my left foot got kind of tired, which is a good thing.

I don't think I'm going to run in them all the time. For one thing, Sonia just bought me some nice trail running shoes and she'll kill me if I don't use them. But I'm also a little nervous about hashing in them-- too many roots to run over. Also, it felt a little strange leaving the house in them at first. For some reason I felt exceptionally exposed running out the door in them. I got over it once I actually started running.

Anyway, I'm pretty happy with them.

Sunday, August 24, 2008

Hurt hamstring: 2 hours on C&O Canal/New toys

I'm thinking about running in the EX2 Adventure Off-Road Half-Marathon. Actually, I'm really interested in eventually running an Ultra. I want to see how trail racing is and a half marathon seems like a reasonable distance for me right now-- my long run is right at 12 miles. I have a list of trail races I've compiled, including a trail marathon in about three months (thankfully, right after hurricane season).

So I went out with the intention of doing 2.5 hours today. Except for one little problem: two weeks ago I strained my left hamstring. I shouldn't strain a hamstring, it's just bad form that does that. Basically I have a tendency to throw my foot way out in front of me and pull hard when I want to go fast... a mistake.

So I've been stretching it and icing it and taking ibuprofen and resting for a few weeks. And I finally started running on it again a few days ago. I've gotten good about stretching before the run as well, which I've been terrible about since, well, birth.
Vibram FiveFingers: Gloves for your tootsies
I went out on Rock Creek Parkway, ran down until it meets C&O Canal in Georgetown, and switched over to the Capital Crescent Trail. I was running five minutes and then walking one, which felt lame, but I didn't want to re-injure it.

All went well until I was right at two hours. I was coming back into Georgetown, the sun was sparkling off of the Potomac, scullers were making graceful paths in the water-- one of those moments that are so beautiful. I got carried away and started really pushing it. And then my hamstring gave me one tiny twang! I stopped dead in my tracks and walked it in. Actually, it feels fine now, but I think if I had run three more steps on it I would have to take two more weeks off.

On another note, I went out and bought a new toy today: a pair of Vibram FiveFingers. I was going to buy them online, but I'm glad I didn't-- you really need to size these in person. I know how goofy this looks, but I couldn't resist it. I'm kind of obsessed with the idea of running barefoot, but I can't imaging doing it on trail. Actually, the picture doesn't do them justice: they look way goofier than that. They look kind of like frog feet or something. Sonia just rolled her eyes when she saw them and Daniel told me that he does not want to be seen with me wearing those. So mission accomplished.

I think I'm just doing burpees tomorrow, but I'm going to try these goofy things out the day after. Just in case you didn't think I was strange enough.

Tuesday, August 19, 2008

Outlook: VBA Script to display all unread messages

I wanted a button on Outlook that would let me catch up with all my emails by opening each unread email one by one. There is a button on the reader pane for this, but I specifically wanted to be able to do this quickly from the main window. Also I was casting about for something geeky to do and this caught my eye.

Here is the code to make it happen:


Sub find_unread()
On Error GoTo eh:
' I want to be able to catch up by reading all my unread messages
Dim ns As Outlook.NameSpace
Dim folder As MAPIFolder
Dim item As Object
Dim msg As MailItem

' Open the inbox folder
Set ns = Session.Application.GetNamespace("MAPI")
Set folder = ns.GetDefaultFolder(olFolderInbox)

' Loop through items in the inbox folder
For Each item In folder.Items
DoEvents
If (item.Class = olMail) And (item.UnRead) Then
' This message has not been read. Display it modally
Set msg = item
msg.Display True
' uncomment the next line to have it only find one unread
' message at a time
'Exit For
End If
Next

' If you uncommented the line to read individual messages,
' comment the next line so you don't get a message box
' every single message!

MsgBox "All messages in Inbox are read", vbInformation, "All Read"
Exit Sub
eh:
MsgBox Err.Description, vbCritical, Err.Number
End Sub

To make this work,
  1. hit alt-F11 to show the macro window,
  2. double-click ThisOutlookSession
  3. and paste this code into the resulting window.
  4. Save it, then back in the Outlook primary window, right-click the button bar and choose Customize....
  5. On the "Commands" tab, scroll down to "Macros" in the Categories window and click "Macros"
  6. Select your macro in the "Commands" window and drag it over to the button bar.

You can clean up the button if you like.

To use the command, press the button and each unread message will open, one at a time. When you close a message, the next message will open.

Friday, August 15, 2008

Historically Most Active Hurricane Day: September 10


I recently looked over some hurricane data from 1851 until this year. I got curious: on what day of the year is there the most hurricane activity? Answer: September 10. There have been 96 active hurricanes on that day since 1851.

To create this graph, I downloaded a data set from the NOAA Historical Hurricane Tracks page: http://maps.csc.noaa.gov/hurricanes/download.jsp. I downloaded the dataset for both basins. It comes in the form of an ESRI ARCMap dhape file, but there is a dBase dbf file that can be imported into Micosoft Access (if you try this, you may run into some trouble unless you rename the DBF file to have a normal eight character file name).

I used Microsoft Excel to query the data from the Access database I had created and create the graph. I had to be careful in my query not to double count hurricanes that had more than one weather advisory on the same date.