Open rmgpanw opened 4 years ago
I think there are a couple of things that caused syntax errors in the initial code:
-F
(field separator) option needs to be followed by an argument. However, I think this can be omitted as the default is whitespace so tab / space should be fine.=
operator should be <
(or ==
for "equal to", but that's not what we want)0.0000.
should be 0.00001
The following should work:
awk '$8 < 0.00001' sample.txt
(it wont show any output as there is no variant with P < 0.00001, so to check you can change it to e.g. awk '$8 < 0.1' sample.txt
If you want to preserve the header: awk 'NR==1 || $8 < 0.1' sample.txt
Problem summary
or download here: sample.txt
I have tried the following, which does not work
awk -F '{if ( $8 = 0.0000.) print $0 }' sample.txt
I get 'syntax error' when I run this with the sample.txt file
Could someone please advise me on how to improve on this? Thanks!