I tried also to run the code on the file. It's run perfectly on my system after throwing away the header.
I still suspect you have somewhere unexpected characters in your input. The errors point to that. This can be invisible characters that aren't visible and can't be automatically transformed by Perl to a number. Try to validate your input by something like this:
unless ($F2[2] =~ /^[+-]?\d+\.?\d*$/) {print "not an floating number\n +";} #assumes "." as digital separator, no thousand separator unless ($F3[2] =~ /^[+-]?\d+\.?\d*$/) {print "not an floating number\n +";}
Look also to http://www.perlmonks.org/?node_id=622704 for a more in detail explanation. It is possible that later versions of Perl are more robust in transforming a string to a number.
Martell
In reply to Re^6: Error when running on larger files
by martell
in thread Error when running on larger files
by K_Edw
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |