Hi,
I have a large csv file which has data for every 15 minutes and I need only the hourly data. I would like to keep the first line, delete the next three lines, keep the fourth etc...
Sample of the orig data:
Code:
01/01/2009 0:00:57 sleep 84 8.4 -13.11
01/01/2009 0:16:12 sleep 84 8.4 -13.11
01/01/2009 0:31:27 sleep 84 8.4 -13.11
01/01/2009 0:46:42 sleep 84 8.4 -13.11
01/01/2009 1:01:57 sleep 84 8.4 -13.11
01/01/2009 1:17:12 sleep 84 8.4 -13.11
01/01/2009 1:32:27 sleep 84 8.4 -13.11
01/01/2009 1:47:42 sleep 81 8.1 -13.28
01/01/2009 2:02:57 sleep 81 8.1 -13.28
Desired output from above data:
Code:
01/01/2009 0:00:57 sleep 84 8.4 -13.11
01/01/2009 1:01:57 sleep 84 8.4 -13.11
01/01/2009 2:02:57 sleep 81 8.1 -13.28
A simple awk or bash command would suffice as I only need to perform this operation on 1 or 2 files.
Any help is appreciated!
Thanks.