Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Question about parsing columns when using Text::CSV

by borisz (Canon)
on Jan 06, 2009 at 15:15 UTC ( #734456=note: print w/replies, xml ) Need Help??


in reply to Question about parsing columns when using Text::CSV

Use sprintf to truncate the numbers.
my @columns = map { sprintf("%.3f", $_) } $csv->fields();
should work. untested
Boris

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://734456]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (6)
As of 2016-12-09 23:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (158 votes). Check out past polls.