Skip to main content
2 of 3
edited tags
Jeff Schaller
  • 68.8k
  • 35
  • 122
  • 266

How to get max, min and mean from values in column 3?

I have data structured like this

X 43808504 G 1 ^]. < X 43808505 C 3 . 4 X 43808506 T 8 . ? X 43808507 G 5 . C 

I want to get the max (8), min (1) and mean (4.25) from column 4 and write that to a file.

I've been wrestling with sorting and then cutting data away but that seems really inefficient.

Thanks for any help