cd $HOME/biosoft
wget http://bioinfo.mpipz.mpg.de/shoremap/SHOREmap_v3.4.tar.gz
## 替换SHOREmap下的dislin的一些文件
tar -zxvf SHOREmap_v3,4
rm dislin/*dislin_d.*
cp $DISLIN/*dislin_d.* dislin
## 编辑/etc/profile或.bashrc
vi .bashrc
export LD_LIBRARY_PATH=$HOME/src/SHOREmap_v3.4/dislin
## 退出保存.bashrc: Esc+:wq
source .bashrc
## 到之前安装的文件夹下
cd & cd src/SHOREmap_v3.4
(可选,如果没有g++)sudo apt-get install build-essential
make
## 将编译文件拷贝到习惯的文件夹中,然后添加执行路径
cp SHOREmap ../../biosoft/SHOREmap_v3.4
echo "export $HOME/bisoft/SHOREmap_v3.4" >> ~/.bashrc
最后,可以重新启动一下bash验证
官方网站提供的两个常见问题的解答
Note 1: if the compilation complains like "/usr/bin/ld: cannot find -lXt" (or "/usr/bin/ld: cannot find -ldislin_d"), please open the makefile with the command
vi makefile
Press keys 'esc' and 'i' on the keyboard to edit makefile; move the cursor with arrow keys to the position before -lXt, and edit -L/path/to/libXt.so/; if '-ldislin_d' is not found, edit -L/path/to/dislin_d/ before -ldislin_d). After that, press keys 'esc', type in :wq, and press enter to save editing and quit vi. ('-L' tells the linker where to find the library given by -l)
Note 2: if '/usr/lib/ld: warning: libXm.so.3, needed by ./dislin/libdislin_d.so, not found (try using -rpath or -rpath-link)' occurs, and you have installed libmotif4, do the following:
cp /usr/lib/libXm.so.4 /usr/lib/libXm.so.3
We can make SHOREmap avaiable for general use by inserting the following command into /etc/profile
## If you are trying to view VCF 4.2 files in IGV - you may run into issues. This function might help you.
## This script will:
## 1. Rename the file as version 4.1
## 2. Replace parentheses in the INFO lines (IGV doesn't like these!)
function vcf_downgrade() {
outfile=${1/.bcf/}
outfile=${outfile/.gz/}
outfile=${outfile/.vcf/}
bcftools view --max-alleles 2 -O v $1 | \
sed "s/##fileformat=VCFv4.2/##fileformat=VCFv4.1/" | \
sed "s/(https://" | \
sed "s/)//" | \
sed "s/,Version=\"3\">/>/" | \
bcftools view -O z > ${outfile}.dg.vcf.gz
tabix ${outfile}.dg.vcf.gz
}
其实对于单个文件而言,可以直接用以下命令
infile=BG.vcf
outfile=BG.vcf
bcftools view --max-alleles 2 -O v ${infile} | \
sed "s/##fileformat=VCFv4.2/##fileformat=VCFv4.1/" | \
sed "s/(https://" | \
sed "s/)//" | \
sed "s/,Version=\"3\">/>/" | \
bcftools view -O z > ${outfile}.dg.vcf.gz
候选marker文件。也就是使用SHOREmap convert通过vcf生成的converted_variant.txt,每一列的含义如下。
1 Project name
2 Identity of chromosome
3 Position of the SNP-marker
4 Reference base
5 Alternative base (or mutant base)
6 Quality of the alternative base (ranging from 0 to 40)
7 Number of reads supporting the predicted base
8 Ratio of reads supporting the predicted base to total coverage