perldummie has asked for the wisdom of the Perl Monks concerning the following question:
I am trying to write a perl script that prints out the lowest and highest values of Column3. But since S12 has value 1 appear more often than S11 in column3 based on the value in column1, I need the script to give me as a result the line of S12 as the lowest column3 value (2925 S12 1 ). Is there an easy way to do this? Please keep the script as simple as possible so that I can actually follow what you are doing and learn from it. Thanks for your help!Column1 Column2 Column3 2870 S11 1 574 S11 2 317 S11 3 31 S11 4 1 S11 6 1 S11 7 2925 S12 1 8 S12 5 1 S12 6 1 S12 9
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: max and min values in 3-column file
by ikegami (Patriarch) on Feb 06, 2011 at 02:38 UTC | |
|
Re: max and min values in 3-column file
by jdporter (Paladin) on Feb 06, 2011 at 04:17 UTC | |
|
Re: max and min values in 3-column file
by BrowserUk (Patriarch) on Feb 06, 2011 at 06:45 UTC | |
|
Re: max and min values in 3-column file
by jwkrahn (Abbot) on Feb 06, 2011 at 07:31 UTC | |
by perldummie (Initiate) on Feb 06, 2011 at 14:31 UTC | |
by tospo (Hermit) on Feb 07, 2011 at 09:48 UTC |