<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>生信菜鸟团 &#187; sratoolkit</title>
	<atom:link href="http://www.bio-info-trainee.com/tag/sratoolkit/feed" rel="self" type="application/rss+xml" />
	<link>http://www.bio-info-trainee.com</link>
	<description>欢迎去论坛biotrainee.com留言参与讨论，或者关注同名微信公众号biotrainee</description>
	<lastBuildDate>Sat, 28 Jun 2025 14:30:13 +0000</lastBuildDate>
	<language>zh-CN</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.1.33</generator>
	<item>
		<title>自学CHIP-seq分析第三讲~公共测序数据下载</title>
		<link>http://www.bio-info-trainee.com/1738.html</link>
		<comments>http://www.bio-info-trainee.com/1738.html#comments</comments>
		<pubDate>Tue, 05 Jul 2016 00:26:27 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[tutorial]]></category>
		<category><![CDATA[CHIP-seq]]></category>
		<category><![CDATA[fastq]]></category>
		<category><![CDATA[SRA]]></category>
		<category><![CDATA[sratoolkit]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=1738</guid>
		<description><![CDATA[这一步跟自学其它高通量测序数据处理一样，就是仔细研读paper，在里面找到作者把 &#8230; <a href="http://www.bio-info-trainee.com/1738.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<div>这一步跟自学其它高通量测序数据处理一样，就是仔细研读paper，在里面找到作者把原始测序数据放在了哪个公共数据库里面，一般是NCBI的GEO，SRA，本文也不例外，然后解析样本数，找到下载链接规律</div>
<blockquote>
<div>## step1 : download raw data</div>
<div>cd ~</div>
<div>mkdir CHIPseq_test &amp;&amp; cd CHIPseq_test</div>
<div>mkdir rawData &amp;&amp; cd rawData</div>
<div>## batch download the raw data by shell script :</div>
<div>for ((i=593;i&lt;601;i++)) ;do wget <a href="ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP033/SRP033492/SRR1042">ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP033/SRP033492/SRR1042</a>$i/SRR1042$i.sra;done</div>
<div></div>
</blockquote>
<div>很容易就下载了8个测序文件，每个样本的数据大小，测序量如下</div>
<div>
<blockquote>
<div>621M Jun 27 14:03 SRR1042593.sra (16.9M reads)</div>
<div>2.2G Jun 27 15:58 SRR1042594.sra (60.6M reads)</div>
<div>541M Jun 27 16:26 SRR1042595.sra (14.6M reads)</div>
<div>2.4G Jun 27 18:24 SRR1042596.sra (65.9M reads)</div>
<div>814M Jun 27 18:59 SRR1042597.sra (22.2M reads)</div>
<div>2.1G Jun 27 20:30 SRR1042598.sra (58.1M reads)</div>
<div>883M Jun 27 21:08 SRR1042599.sra (24.0M reads)</div>
<div>2.8G Jun 28 11:53 SRR1042600.sra (76.4M reads)</div>
</blockquote>
<div> 虽然下载的SRA格式数据也是一个很流行的标准，但它只是数据压缩的标准，几乎没有软件能直接跟SRA的格式的测序数据来进行分析，我们需要转成fastq格式，代码如下：</div>
<div></div>
</div>
<blockquote>
<div>## step2 :  change sra data to fastq files.</div>
<div>## cell line: MCF7 //  Illumina HiSeq 2000 //  50bp // Single ends // phred+33</div>
<div>## <a href="http://www.ncbi.nlm.nih.gov/geo/query/acc.cgi?acc=GSE52964">http://www.ncbi.nlm.nih.gov/geo/query/acc.cgi?acc=GSE52964</a></div>
<div>## <a href="ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP033/SRP033492">ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP033/SRP033492</a></div>
<div>ls *sra |while read id; do ~/biosoft/sratoolkit/sratoolkit.2.6.3-centos_linux64/bin/fastq-dump $id;done</div>
<div>rm *sra</div>
</blockquote>
<div>解压的详情如下，可以看到SRA格式有6~9倍的压缩了，比zip格式压缩的2~3倍高多了</div>
<div>##  621M --&gt; 3.9G</div>
<div>##  2.2G --&gt; 14G</div>
<div>##  541M --&gt; 3.3G</div>
<div>##  2.4G --&gt; 15G</div>
<div></div>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/1738.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>自学miRNA-seq分析第三讲~公共测序数据下载</title>
		<link>http://www.bio-info-trainee.com/1703.html</link>
		<comments>http://www.bio-info-trainee.com/1703.html#comments</comments>
		<pubDate>Sat, 25 Jun 2016 09:08:43 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[未分类]]></category>
		<category><![CDATA[miRNA-seq]]></category>
		<category><![CDATA[ncbi]]></category>
		<category><![CDATA[SHRiMP]]></category>
		<category><![CDATA[sratoolkit]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=1703</guid>
		<description><![CDATA[前面已经讲到了该文章的数据已经上传到NCBI的SRA数据中心，所以直接根据索引号 &#8230; <a href="http://www.bio-info-trainee.com/1703.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>前面已经讲到了该文章的数据已经上传到NCBI的SRA数据中心，所以直接根据索引号下载，然后用SRAtoolkit转出我们想要的fastq测序数据即可。下载的数据一般要进行质量控制，可视化展现一下质量如何，然后根据大题测序质量进行简单过滤。所以需要提前安装一些软件来完成这些任务，包括： sratoolkit /fastx_toolkit /fastqc/bowtie2/hg19/miRBase/SHRiMP</p>
<p>下面是我用新服务器下载安装软件的一些代码记录，因为fastx_toolkit /fastqc我已经安装过，就不列代码了，还有miRBase的下载，我在前面第二讲里面提到过，传送门：<a href="http://www.bio-info-trainee.com/1697.html">自学miRNA-seq分析第二讲~学习资料的搜集</a><span id="more-1703"></span></p>
<blockquote>
<div>## pre-step: download sratoolkit /fastx_toolkit_0.0.13/fastqc/bowtie2/hg19/miRBase/SHRiMP</div>
<div>## <a href="http://www.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=software">http://www.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=software</a></div>
<div>## <a href="http://www.ncbi.nlm.nih.gov/books/NBK158900/">http://www.ncbi.nlm.nih.gov/books/NBK158900/</a></div>
<div> ## 我这里特意挑选的二进制版本程序下载的，这样直接解压就可以用，但是需要挑选适合自己的操作系统的程序。</div>
<div>cd ~/biosoft</div>
<div>mkdir sratoolkit &amp;&amp;  cd sratoolkit</div>
<div>wget <a href="http://ftp-trace.ncbi.nlm.nih.gov/sra/sdk/2.6.3/sratoolkit.2.6.3-centos_linux64.tar.gz">http://ftp-trace.ncbi.nlm.nih.gov/sra/sdk/2.6.3/sratoolkit.2.6.3-centos_linux64.tar.gz</a></div>
<div>##</div>
<div>##  Length: 63453761 (61M) [application/x-gzip]</div>
<div>##  Saving to: "sratoolkit.2.6.3-centos_linux64.tar.gz"</div>
<div>tar zxvf <strong>sratoolkit.2.6.3-centos_linux64.tar.gz</strong></div>
<div></div>
<div>cd ~/biosoft</div>
<div>mkdir bowtie &amp;&amp;  cd bowtie</div>
<div>wget <a href="https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.2.9/bowtie2-2.2.9-linux-x86_64.zip/download">https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.2.9/bowtie2-2.2.9-linux-x86_64.zip/download</a></div>
<div>#Length: 27073243 (26M) [application/octet-stream]</div>
<div>#Saving to: "download"</div>
<div> mv download  bowtie2-2.2.9-linux-x86_64.zip</div>
<div> unzip <strong>bowtie2-2.2.9-linux-x86_64.zip</strong></div>
<div></div>
<div>## <a href="http://compbio.cs.toronto.edu/shrimp/">http://compbio.cs.toronto.edu/shrimp/</a></div>
<div>mkdir SHRiMP &amp;&amp;  cd SHRiMP</div>
<div>wget <a href="http://compbio.cs.toronto.edu/shrimp/releases/SHRiMP_2_2_3.lx26.x86_64.tar.gz">http://compbio.cs.toronto.edu/shrimp/releases/SHRiMP_2_2_3.lx26.x86_64.tar.gz</a></div>
<div>tar zxvf<strong> SHRiMP_2_2_3.lx26.x86_64.tar.gz </strong></div>
<div>cd SHRiMP_2_2_3</div>
<div>export SHRIMP_FOLDER=$PWD  ## 这个软件使用的时候比较奇葩，需要设置到环境变量，不能简单的调用全路径</div>
</blockquote>
<div>SHRiMP这个软件比较小众，我也是第一次听说过，本来我计划是能用bowtie搞定，就不麻烦了，但是第一次比对出了一个bug，就是下载的miRNA序列里面的U没有转换成T，所以导致比对率非常之低，所以我不得不根据文章里面记录的软件SHRiMP 来做比对，最后发现比对率完全没有改善，搞得我都在怀疑是不是作者乱来了。</div>
<div>下面是下载数据，质量控制的代码，希望大家可以照着运行一下：</div>
<div>
<blockquote>
<div>## step1 : download raw data</div>
<div>mkdir miRNA_test &amp;&amp; cd miRNA_test</div>
<div>echo {14..19} |sed 's/ /\n/g' |while read id; \</div>
<div>do  wget "<a href="ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP045/SRP045420/SRR15427$id/SRR15427$id.sra">ftp://ftp-trace.ncbi.nlm.nih.gov/sra/sra-instant/reads/ByStudy/sra/SRP/SRP045/SRP045420/SRR15427$id/SRR15427$id.sra</a>"  ;\</div>
<div>done</div>
<div></div>
<div>## step2 :  change sra data to fastq files.</div>
<div>## 主要是用shell脚本来批量下载</div>
<div>ls *sra |while read id; do ~/biosoft/sratoolkit/sratoolkit.2.6.3-centos_linux64/bin/fastq-dump $id;done</div>
<div>rm *sra</div>
<div></div>
<div>##  33M --&gt; 247M</div>
<div>#Read 1866654 spots for SRR1542714.sra</div>
<div>#Written 1866654 spots for SRR1542714.sra</div>
<div></div>
<div></div>
<div>## step3 : download the results from paper</div>
<div>## <a href="http://www.bio-info-trainee.com/1571.html">http://www.bio-info-trainee.com/1571.html</a></div>
<div>## <a href="ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE1nnn/GSE1009/suppl/GSE1009_RAW.tar">ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE1nnn/GSE1009/suppl/GSE1009_RAW.tar</a></div>
<div></div>
<div>mkdir paper_results &amp;&amp; cd paper_results</div>
<div>wget <a href="ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE60nnn/GSE60292/suppl/GSE60292_RAW.tar">ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE60nnn/GSE60292/suppl/GSE60292_RAW.tar</a></div>
<div>## tar xvf GSE60292_RAW.tar</div>
<div>ls *gz |while read id ; do (echo $id;zcat $id | cut -f 2 |perl -alne '{$t+=$_;}END{print $t}');done</div>
<div>ls *gz |xargs gunzip</div>
<div></div>
<div></div>
<div></div>
<div>## step4 : quality assessment</div>
<div></div>
<div>ls *fastq | while read id ; do ~/biosoft/fastqc/FastQC/fastqc $id;done</div>
<div>## Sequence length 8-109</div>
<div>## %GC 52</div>
<div>## Adapter Content passed</div>
<div></div>
<div>## write a script : :: cat &gt;filter.sh</div>
<div></div>
<div>ls *fastq |while read id</div>
<div>do</div>
<div>echo $id</div>
<div>~/biosoft/fastx_toolkit_0.0.13/bin/fastq_quality_filter<strong> -v -q 20 -p 80 -Q33</strong>  -i $id -o tmp ;</div>
<div>~/biosoft/fastx_toolkit_0.0.13/bin/fastx_trimmer <strong>-v -f 1 -l 27</strong> <strong>-i tmp  -Q33 -z</strong> -o ${id%%.*}_clean.fq.gz ;</div>
<div>done</div>
<div>rm tmp</div>
<div></div>
<div>##<strong> discarded 12%~~49%%</strong></div>
<div>ls *_clean.fq.gz | while read id ; do ~/biosoft/fastqc/FastQC/fastqc $id;done</div>
<div></div>
<div>mkdir QC_results</div>
<div>mv *zip *html QC_results</div>
</blockquote>
</div>
<div>这个代码是我自己根据文章的理解写出的，因为我本身不擅长miRNA数据分析，所以在进行QC的时候参数选择可能并不是那么友好，如果有高手能指正就最好了，可以直接打我电话告诉我，或者发邮箱给我，邮箱用户名是jmzeng1314，是163邮箱。</div>
<div>
<div>~/biosoft/fastx_toolkit_0.0.13/bin/fastq_quality_filter<strong> -v -q 20 -p 80 -Q33</strong>  -i $id -o tmp ;</div>
<div>~/biosoft/fastx_toolkit_0.0.13/bin/fastx_trimmer <strong>-v -f 1 -l 27</strong> <strong>-i tmp  -Q33 -z</strong> -o ${id%%.*}_clean.fq.gz ;</div>
<div>最后得到的clean.fq.gz系列文件，就是我需要进行比对的序列啦。</div>
<div></div>
<div></div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/1703.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SRA工具sratoolkit把原始测序数据转为fastq格式</title>
		<link>http://www.bio-info-trainee.com/338.html</link>
		<comments>http://www.bio-info-trainee.com/338.html#comments</comments>
		<pubDate>Thu, 19 Mar 2015 01:32:04 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[基础数据库]]></category>
		<category><![CDATA[基础软件]]></category>
		<category><![CDATA[reads]]></category>
		<category><![CDATA[shell]]></category>
		<category><![CDATA[sratoolkit]]></category>
		<category><![CDATA[原始数据]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=338</guid>
		<description><![CDATA[一，下载该软件 wget http://ftp-trace.ncbi.nlm.n &#8230; <a href="http://www.bio-info-trainee.com/338.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>一，下载该软件</p>
<p>wget http://ftp-trace.ncbi.nlm.nih.gov/sra/sdk/current/sratoolkit.current-ubuntu64.tar.gz</p>
<p>tar xzf sratoolkit.current-centos_linux64.tar.gz</p>
<p>解压直接使用即可，里面有一大堆的软件，针对不同的测序仪，不同的数据<span id="more-338"></span></p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式448.png"><img class="alignnone size-full wp-image-339" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式448.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式448" width="600" height="277" /></a></p>
<p>我一般只用/home/jmzeng/down_software/sratoolkit.2.3.5-2-ubuntu64/bin/fastq-dump</p>
<p>/home/jmzeng/down_software/sratoolkit.2.3.5-2-ubuntu64/bin/fastq-dump --split-3 SRR1793917.sra</p>
<p>二：下载数据</p>
<p>首先去NCBI里面搜索并找到你想要的数据的SRA地址，然后写脚本批量下载。</p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式826.png"><img class="alignnone size-full wp-image-340" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式826.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式826" width="644" height="187" /></a></p>
<p>如果文献里面的SRA号，那么可以直接打开NCBI里面的搜索界面下载</p>
<p>如果文献里面是SRP号，那么该SRP会涉及到好几个SRA数据，得一个个开网站下载</p>
<p>三：用命令解压数据</p>
<p>下载之后的数据是</p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1008.png"><img class="alignnone size-full wp-image-341" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1008.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式1008" width="366" height="171" /></a></p>
<p>非常简单的命令，就可以把当前文件夹下的所有sra都解压开来！</p>
<p>[shell]</p>
<p>for i in *sra<br />
do<br />
echo $i<br />
/home/jmzeng/bio-soft/sratoolkit.2.3.5-2-ubuntu64/bin/fastq-dump --split-3 $i<br />
done</p>
<p>[/shell]</p>
<p>解压的同时它也会显示每个SRA文件的数据量</p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1064.png"><img class="alignnone size-full wp-image-342" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1064.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式1064" width="405" height="432" /></a></p>
<p>&nbsp;</p>
<p>四：结果文件解读</p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1235.png"><img class="alignnone size-full wp-image-343" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1235.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式1235" width="417" height="486" /></a></p>
<p>可以看到，每个SRA文件都产生了两个reads，分别是左右两端测序，说明这个SRA文件是双端测序策略。</p>
<p>随便打开一个fastq文件可以看到，它的读长是300bp</p>
<p><a href="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1479.png"><img class="alignnone size-full wp-image-344" src="http://www.bio-info-trainee.com/wp-content/uploads/2015/03/SRA工具sratoolkit把原始测序数据转为fastq格式1479.png" alt="SRA工具sratoolkit把原始测序数据转为fastq格式1479" width="645" height="170" /></a></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/338.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
