[ILUG] perl file processing
furlongm at hotmail.com
Wed Oct 8 18:26:08 IST 2008
Hi, question for any perl gurus on the list.
I have a about 250 files to process that have the following format:
What I'm trying to do is find the line in the file that says "Stratified cross-validation". When I find that, I know I have the right section, and I want to move down to the table below labelled "Detailed Accuracy By Class" and sum each of the columns and print out an average for each column.
The number of lines before "Stratified cross-validation" varies per file, as does the number of classes in the file (and hence the divisor for the average).
If anyone can help with a perl script (or the basis of one), I'd be very grateful, as my bash scripting is getting me nowhere with this one..
Get the next generation of Free Windows Live Services
More information about the ILUG