and getting the value greater than 50.000 and printing that entry separately. this is my program i wrote but im getting error uninitialized value in split:ENSMUSG00000027831 ENSTBEG00000008938 ortholog_one2one Euthe +ria 56.2942008486563 ENSMUSG00000027831 ENSLAFG00000011038 ortholog_one2one Euther +ia 58.5845347313237 ENSMUSG00000027831 ENSDORG00000014560 ortholog_one2one Sciuro +gnathi 43.9759036144578
What is wrong with the code? How can i rectify it. I am not sure with what datatype to use for each value?use strict; use warnings; use Getopt::std; my $le = "lethal_results.txt"; open(LE , "<", $le) or die ("Unable to open file $le: $!"); my @le_data = <LE>; my $le_data; close (LE); for( my$i=1; $i<= @le_data; $i++) { my @line = split(/\s+/,$le_data[$i]); my $width = 11; if(@le_data[5] >= 50.000) { my $data = $le_data[$i]; chomp $data; printf("%s%${width}s%${width}s%\t\t%.6g\n", $le_data[1],$le_data[2],$l +e_data[4],$le_data[6]); }
In reply to Parsing in perl by Nalababu
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |