Hello, I need to sort from my file, I have 3 columns: the first would be the chromosome (1,2,3,4,5..28, W, Z), the second would be the position on this chromosome and the last one they would be values.
When I do the sort -n
I have the chromosomes drawn in 10,11,12,13 .... but I want the order: 1,2,3 ... 28, W, Z. The second column would like the values from lowest to highest. The third column does not matter.
Example of my input
10 247 0.02
10 445 0.04
10 447 0.08
11 81 0.04
11 91 0.01
1 102 0.03
1 105 0.05
What would be the best command?