Dreamhost, excellent hosting company on the whole but I had a php cron job setup that worked fine from my browser but failed with strange error messages when run from the command line.
Could it be, I wondered, that the path to php I’d given in my cron job wasn’t the path to the version of php I was running on the website. And that was the problem. My website was running 5.x but from the command line I was running 4.x
A quick fix so that the cron job referenced the path to php 5:
30 14 * * * * /usr/local/php5/bin/php [path to my script]/writeHolidayArray.php
and everything worked fine.