Hi Raj,
some comments on your code.
On Sun, 20 Sep 2015 18:19:30 -0300
Raj Barath wrote:
> Hi,
>
> Is this is what you're looking for ?
>
Always start with "use strict;" and "use warnings;" or equivalent.
> my %hash;
>
> while( my $line = ){
1. There should be a space before the "(".
2.
+perl-beginners forgot to hit reply all
On Sun, Sep 20, 2015, 7:00 PM Raj Barath wrote:
> Hi,
> I have added the comments. But to understand even better please go through
> the official documentation such as:
> http://perldoc.perl.org/index-tutorials.html
>
>
> my %hash;
>
> while( my $line = )
Dear Raj,
Thanks.
Could you comment on the lines of code so that i can understand better ?
Best
On Sep 20, 2015, at 10:19 PM, Raj Barath
mailto:barat...@live.com>> wrote:
Hi,
Is this is what you're looking for ?
my %hash;
while( my $line = ){
chomp $line;
my ( $scaf, $pro_per ) = $line =~
Hi,
Is this is what you're looking for ?
my %hash;
while( my $line = ){
chomp $line;
my ( $scaf, $pro_per ) = $line =~ m/\sHit=(.*?)\s.*?Percent_id=(.*?)$/g;
push @{$hash{$1}}, $2;
}
print Dumper (\%hash);
Output:
$VAR1 = {
'scaffold293_size341291' => [