数据去冗余流程

############pipeline.removeDup##################
#输入参数:org, 比如hg19
#结果文件:newVersionGene.combined.gtf: lncRNA基因文件
#结果文件:${org}.tcons.nc.cnci:非编码的cnci值
#结果文件:${org}.tcons.coding.cnci:编码的cnci值
 
org=$1;
#分离coding,和noncoding
awk '$4~/NR/{print  $0;}' ${org}.refseq.bed > ${org}.refseq.nr.bed
awk '$4~/NM/{print  $0;}' ${org}.refseq.bed > ${org}.refseq.nm.bed
 
 
perl /leofs/noncode/NONCODEv4/cmds/dup.pl ${org}.refseq.nm.bed  3 > ${org}.refseq.nm.bed.withDup
bedToGtf.sh ${org}.refseq.nm.bed.withDup > ${org}.refseq.nm.gtf
perl /leofs/noncode/NONCODEv4/cmds/dup.pl ${org}.refseq.nr.bed  3 > ${org}.refseq.nr.bed.withDup
bedToGtf.sh ${org}.refseq.nr.bed.withDup > ${org}.refseq.nr.gtf
 
#分离ENSEMBL中的coding,此处codnig为有对应蛋白产物的转录本
awk -F "," '$3{print $2;}' ensemblProtein > enst.coding
awk -F "," '{print $2;}' ensemblProtein > enst.all
sub.pl enst.coding enst.all > enst.nc
 
perl /leofs/noncode/NONCODEv4/cmds/leftJoin.pl enst.nc 1 ${org}.ensembl.bed 4 | cut -f 2,3,4,5,6,7,8,9,10,11,12,13  | awk '$1' > ${org}.ensembl.nc.bed
perl /leofs/noncode/NONCODEv4/cmds/leftJoin.pl enst.coding 1 ${org}.ensembl.bed 4 | cut -f 2,3,4,5,6,7,8,9,10,11,12,13| awk '$1' > ${org}.ensembl.coding.bed
 
perl /leofs/noncode/NONCODEv4/cmds/dup.pl ${org}.ensembl.coding.bed  3 > ${org}.ensembl.coding.bed.withDup
bedToGtf.sh ${org}.ensembl.coding.bed.withDup > ${org}.ensembl.coding.gtf
perl /leofs/noncode/NONCODEv4/cmds/dup.pl ${org}.ensembl.nc.bed  3 > ${org}.ensembl.nc.bed.withDup
bedToGtf.sh ${org}.ensembl.nc.bed.withDup > ${org}.ensembl.nc.gtf
 
bedToGtf.sh v3.fa.blat.bed > v3.gtf
#合并v3, refseq, ensembl
 
cuffcompare -r v3.gtf -o mydata -C ${org}.refseq.nr.gtf ${org}.ensembl.nc.gtf v3.gtf
 
cuffcompare -r ${org}.ensembl.coding.gtf -o mydataVsEnsCoding mydata.combined.gtf -C
awk '$4 == "="{print $5;}' mydataVsEnsCoding.tracking | perl -ne '$_ =~ /q1:.*?\|(.*?)\|/; print $1."\n";' > tcons.maybeCoding.ensembl
cuffcompare -r ${org}.refseq.nm.gtf -o mydataVsRefCoding mydata.combined.gtf -C
awk '$4 == "="{print $5;}' mydataVsRefCoding.tracking | perl -ne '$_ =~ /q1:.*?\|(.*?)\|/; print $1."\n";' > tcons.maybeCoding.refSeq
cat tcons.maybeCoding.ensembl tcons.maybeCoding.refSeq | sort | uniq > tcons.maybeCoding
perl /leofs/noncode/NONCODEv4/cmds/gtfSub.pl tcons.maybeCoding mydata.combined.gtf > newVersion_rmCoding.gtf
 
gtf2Bed.pl newVersion_rmCoding.gtf > newVersion_rmCoding.bed
#Get the sequence
twoBitToFa -bed=newVersion_rmCoding.bed ${org}.2bit newVersion_rmCoding.fa
 
perl -ne 'chomp $_; if(/>/){ if($. > 1){ print "\n"; } print $_."\n";}else{ print $_;}' newVersion_rmCoding.fa > newVersion_rmCoding_seqIn1line.fa
 
#Enter CNCI dir
base=`pwd`
 
cd cnci
ln -s $base/newVersion_rmCoding_seqIn1line.fa ${org}.fa
perl CNCI.pl -f ${org}.fa -p 20 -l libsvm-3.0 -o ${org} -b
 
 
grep noncoding  ${org}/cnci.result.file | cut -f 1,3 | sed -e 's/>//' | sed -e 's/score: //' > ../${org}.tcons.nc.cnci
grep coding  ${org}/cnci.result.file | cut -f 1,3 | sed -e 's/>//' | sed -e 's/score: //' > ../${org}.tcons.coding.cnci
cd ..
# Leave out of cnci dir
 
perl $CMD/leftJoin.pl ${org}.tcons.nc.cnci 1 newVersion_rmCoding.bed 4 | cut -f 3,4,5,6,7,8,9,10,11,12,13,14 > newVersion_rmCoding_cnci.bed
 
getBedSeqLength.sh newVersion_rmCoding_cnci.bed | awk '$2>200' | perl $CMD/leftJoin.pl - 1 newVersion_rmCoding_cnci.bed 4 | cut -f 3,4,5,6,7,8,9,10,11,12,13,14 > newVersion_rmCoding_cnci_lnc.bed
 
bedToGtf.sh newVersion_rmCoding_cnci_lnc.bed > newVersion_lnc.gtf
 
cuffcompare -C -o newVersionGene newVersion_lnc.gtf


转载于:https://my.oschina.net/xiechaoyong/blog/209794

Canoco for Windows 是新一代的 CANOCO 软件,是生态学应用软件中用于约束与非约 束排序的最流行工具。Canoco for Windows 整合了排序以及回归和排列方法学,以便得到健 全的生态数据统计模型。Canoco for Windows 包括线性和曲线单峰方法。使用 Canoco for Windows 进行排序,能够洞察: ● 生物群落结构 ● 植物与动物群落以及它们的环境之间的联系 ● 一个对环境和(或)其生物群落的假设冲击所能造成的影响 ● 在生物群落上进行的复杂生态学和生态毒理学实验的相关处理所能造成的影响 一个排序被计算出来后,排序图可以立即显示在显示器上。Canoco 具体独特的能力,可 以说明用协变量表示的背景变异,而用它的扩展工具来进行排列测试,包括测试的互动效果。 这些独特的特性使得 Canoco for Windows 能特别有效的解决应用研究方面的问题。 二 软件模块 The Canoco for Windows 软件包主要包含以下几个模块: ● Canoco for Windows:软件包的核心,用来指定要分析的数据和排序模型,排序方法 以及分析结果的查看等基本操作命令均被集中在该模块的对话框中 ● WcanoImp : 将以电子表格形式(Excel 等)保存的外部数据转化为 CANOCO 识别的 形式 ● CanoDraw 4.0 for Windows:用来绘制各种类型的排序图,同时也可以生成多种等值 线和回归模型图,并进一步深层次发掘排序结果,该模块可以直接从主程序界面工 具栏激活 ● CanoMerge:合并 Canoco 识别的 dta 类型数据文件,并可以将数据文件以带制表分 隔符的文本形式输出(基本常用统计软件均兼容该类型文件),同时该模块具有滤掉 低频率物种的功能 ● PrCoord:对特定数据集进行主坐标分析以及冗余分析
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值