Is there a way to always put NA before (or after) numerical values in so
From:
Peng Yu
Subject:
Is there a way to always put NA before (or after) numerical values in sort?
Date:
Fri, 8 Dec 2017 07:57:02 -0600
Hi,
I want to always put NA before (or after) numerical values being
sorted. Is there a way to control this? Thanks.
~$ printf '%s\n' .1 1 NA | sort -k 1,1rg
1
.1
NA
~$ printf '%s\n' .1 1 NA | sort -k 1,1g
NA
.1
1
--
Regards,
Peng