之前沒有好好預(yù)習(xí)邪意,從新看了教程來做上游分析
首先掘譬,由于Mac終端命令中是不支持wget這個(gè)命令忘蟹,之前安裝conda也一直出問題,好在有Being,生信技能樹搁凸,相關(guān)博客等等解決了第一命令后面的就比較方便了媚值。
一、準(zhǔn)備工作护糖,安裝軟件
#拷貝數(shù)據(jù)到Mac褥芒,download目錄
#安裝conda
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh
chmod 777 Miniconda3-latest-MacOSX-x86_64.sh
bash Miniconda3-latest-MacOSX-x86_64.sh
chmod 777 activate
conda --help
conda env list
#創(chuàng)建小環(huán)境
conda create -n python2 python=2
#設(shè)置通道
conda config --add channels bioconda
conda config --add channels conda-forge
conda config --add channels genomedk
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda/
#激活小環(huán)境安裝軟件
conda activate python2
conda install -y bwa sra-tools trim-galore samtools deeptools homer meme macs2 bowtie bowtie2
#退出小環(huán)境
conda deactivate
#切換目錄
cd fly/
cd CHIP-SEQ/
ls
cd merge/
二、激活小環(huán)境使用macs2 call peaks
#激活小環(huán)境 macs2 callpeak
conda activate python2
ls *WT*bam |while read id;do ( macs2 callpeak -t $id -c Input_WT.merge.bam -f BAM -g dm -n ${id%%.*} -q 0.01 );done
三嫡良、輸出結(jié)果
INFO @ Mon, 14 Oct 2019 16:19:12:
# Command line: callpeak -t Ez_WT.merge.bam -c Input_WT.merge.bam -f BAM -g dm -n Ez_WT -q 0.01
# ARGUMENTS LIST:
# name = Ez_WT
# format = BAM
# ChIP-seq file = ['Ez_WT.merge.bam']
# control file = ['Input_WT.merge.bam']
# effective genome size = 1.20e+08
# band width = 300
# model fold = [5, 50]
# qvalue cutoff = 1.00e-02
# The maximum gap between significant sites is assigned as the read length/tag size.
# The minimum length of peaks is assigned as the predicted fragment length "d".
# Larger dataset will be scaled towards smaller dataset.
# Range for calculating regional lambda is: 1000 bps and 10000 bps
# Broad region calling is off
# Paired-End mode is off
INFO @ Mon, 14 Oct 2019 16:19:12: #1 read tag files...
INFO @ Mon, 14 Oct 2019 16:19:12: #1 read treatment tags...
INFO @ Mon, 14 Oct 2019 16:19:15: 1000000
INFO @ Mon, 14 Oct 2019 16:19:19: 2000000
INFO @ Mon, 14 Oct 2019 16:19:22: 3000000
...
INFO @ Mon, 14 Oct 2019 16:50:25: #2.2 Generate R script for model : Spps_WT_model.r
INFO @ Mon, 14 Oct 2019 16:50:25: #3 Call peaks...
INFO @ Mon, 14 Oct 2019 16:50:25: #3 Pre-compute pvalue-qvalue table...
INFO @ Mon, 14 Oct 2019 16:51:32: #3 Call peaks for each chromosome...
INFO @ Mon, 14 Oct 2019 16:52:06: #4 Write output xls file... Spps_WT_peaks.xls
INFO @ Mon, 14 Oct 2019 16:52:06: #4 Write peak in narrowPeak format file... Spps_WT_peaks.narrowPeak
INFO @ Mon, 14 Oct 2019 16:52:06: #4 Write summits bed file... Spps_WT_summits.bed
INFO @ Mon, 14 Oct 2019 16:52:06: Done!
根據(jù)時(shí)間戳看到锰扶,總共運(yùn)行了近40分鐘,此時(shí)文件夾里面就多出來一些文件