Thursday, 5 January 2012

less typing more fun

I keep forgetting this and other handy shortcuts ...

 zcat  is  identical  to  gunzip  -c

but anyway I am surprised at the time difference for the below

on the fly uncompress, sed, compress
----------------------------------------------------------------------- 12:27:21
$ time gunzip -c  bam.cov.csv.gz.chr20.gz |sed 's/ //g' |gzip -c > bam.cov.csv.gz.chr20

real 1m39.638s
user 2m41.098s
sys 0m6.524s

on the fly uncompress, sed
----------------------------------------------------------------------- 13:15:34
$ time gunzip -c  bam.cov.csv.gz.chr20.gz |sed 's/ //g' > bam.cov.csv.gz.chr20


real 1m39.865s
user 1m45.999s
sys 0m5.755s

No comments:

Post a Comment

Datanami, Woe be me