Koda1234 has asked for the wisdom of the Perl Monks concerning the following question:
Hello, I'm very new to perl and I'm having a very difficult time organizing my script so that I can get it to do what I want it to do. Right now, I have a data file that is delimited by space, and has 12 columns, and 84000 rows. The only column that I care about is the 9th column. I am trying to organize the information in that column so that I can "count" the number of values given a conditional if statement (i.e. is the value in the list greater than 2.0, 3.0,...and so on.).
My issue is this. While creating a hash, I know I am supposed to assign a "key" to a "value". How do I specify a value that is >= 2 for example, assuming i'm not going to manually calculate the values greater than 2? And how do I get the hash to pull the information from the column, in my file.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Creating a Hash using only one column in an imported data file
by choroba (Cardinal) on Feb 13, 2017 at 17:41 UTC | |
|
Re: Creating a Hash using only one column in an imported data file
by 1nickt (Canon) on Feb 13, 2017 at 18:30 UTC | |
by Koda1234 (Initiate) on Feb 13, 2017 at 20:53 UTC | |
by 1nickt (Canon) on Feb 13, 2017 at 21:27 UTC | |
by Koda1234 (Initiate) on Feb 13, 2017 at 22:25 UTC | |
by 1nickt (Canon) on Feb 13, 2017 at 22:30 UTC | |
| |
|
Re: Creating a Hash using only one column in an imported data file
by CountZero (Bishop) on Feb 14, 2017 at 14:54 UTC |