<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Grep on Chatomics</title>
    <link>https://divingintogeneticsandgenomics.com/tags/grep/</link>
    <description>Recent content in Grep on Chatomics</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <copyright>&amp;copy; 2018 Ming &#39;Tommy&#39; Tang</copyright>
    <lastBuildDate>Wed, 22 Oct 2014 06:40:00 -0700</lastBuildDate>
    
	<atom:link href="https://divingintogeneticsandgenomics.com/tags/grep/index.xml" rel="self" type="application/rss+xml" />
    
    
    <item>
      <title>speed up grep</title>
      <link>https://divingintogeneticsandgenomics.com/archive/speed-up-grep/</link>
      <pubDate>Wed, 22 Oct 2014 06:40:00 -0700</pubDate>
      
      <guid>https://divingintogeneticsandgenomics.com/archive/speed-up-grep/</guid>
      <description>I had a list of gene names in txt file. There are around 500 genes with one gene name in one line, and I want to filter the gtf file from ensemble Homo_sapines.GRCh37.74gtf.gz
the gtf file contains 2244857 lines. I used grep to do it, but it takes very long (~1 hour).
what I used:
zcat Homo_sapines.GRCh37.74gtf.gz | grep -f gene_names.txt -w &amp;gt; my_genes.gtf
I searched on line, and found several posts in stackoverflow to speed up grep:</description>
    </item>
    
  </channel>
</rss>