Is there an format specification available somewhere for prn files, that fully describes it?
There are two parts to your problem: the header, and the data. For the data, the "origonal.prm" file contains several data-time columns, and a single data column. On the other hand, your Excel file contains several data column, named RCM1, RCM2, etc... Is your goal to create a single file for each RCM? Or does the prn file format accept several data columns?
To address the problem of the header, you can work in two steps: first, you write blank lines and header lines using writeLines(); then, you write the data using write.table() with the argument append = TRUE. That way, the data is written after the header.