Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

5
  • 2
    Do you want to print the min value from column 3 only and the max value from column 4 only? Or if column 3 was: 1000, 120, 200 and column 4 was 100, 230, 10 would you want your results to be: sampleA 1000 10? Commented Aug 9, 2017 at 12:18
  • The max or min could be in column 3 or 4. Because this is DNA ORF information some reads are in reverse like the last line in the above example. Commented Aug 9, 2017 at 14:14
  • So in that case I believe both answers below wont work. NVM just noticed AFSHIN edited his answer. Commented Aug 9, 2017 at 14:30
  • awk's asort function will do the job Commented Aug 9, 2017 at 20:34
  • It appears that columns 1 and 2 have absolutely nothing to do with the output. Are the column 1 values identical in all rows? If not, I don't see how you can even define what the first field of output should be. Commented Aug 9, 2017 at 20:48