posted on 10:28 AM on Thursday 15 August 2013
You can use the following awk snippet to filter the lines of a text file by a certain condition:
cat some_file | awk '{ if($1>1) print $0 }'
The above snippet prints out the line in the text file is the first column has a numeric value greater than one.
See http://stackoverflow.com/questions/8734351/using-awk-to-filter-out-column-with-numerical-ranges for more details.
Why me (12:54 PM on Saturday 17 August 2013)
The family having yogurt cones (07:25 PM on Sunday 11 August 2013)
Using awk to remove genotypes from a VCF file (08:28 AM on Friday 19 September 2014)
Dumping data from Excel files (08:49 AM on Tuesday 21 July 2015)
MySQL data loader (11:48 AM on Thursday 18 September 2014)
Genome size (02:07 PM on Tuesday 29 July 2014)
Script to extract FASTA sequences (01:04 PM on Monday 17 November 2014)