I have a tab delimited file and I want to multiply each value in the file with 50 and the user input value ($df). My code is giving me following error :
Argument "6 20 40 " isn't numeric in multiplication (*) at - line 9, <FILE> line 3.
use warnings; print " Enter the dilution factor. \n"; chomp ($df = <STDIN>); open FILE, "45well.txt" or die $!; while (<FILE>){ chomp $_; @values = split('\t', $_); $val = @values; foreach $val (@values){ $DNA_conc = $val * $df * 50 ; print $DNA_conc; print"\n"; } } close (FILE);
In reply to handling tab delimited files by shaludr
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |