Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re^2: open input files once

by Tux (Canon)
on Jul 14, 2020 at 10:25 UTC ( [id://11119293]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    foreach my $key (grep { !m/\t0$/ } keys %data) {
        my ($chr, $fivep, $threep, $strand) = split m/\t/ => $key;
        say join "\t" => $chr, $fivep, $threep, "-",
            map { $data{$key}{$_} // 0 } @files;
        }
    
  2. or download this
    use Text::CSV_XS qw( csv );
    
    ...
    foreach my $key (sort keys %c7) {
        say join "\t" => (split m/:/ => $key), map { $c7{$key}{$_} // 0 } 
    +@files;
        }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11119293]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (3)
As of 2024-04-25 14:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found