Hi Tim,
I don't mind writing these lines, provided that you write a little how-to for this community. Deal?
BTW, why do you need it as Perl code? I'm not too familiar with rrd, but it's predecessor mrtg would happily take input from a script.
Regards,
Michiel