Created
July 13, 2009 19:19
-
-
Save drio/146378 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
#$coverage_bin -in $a_out_bin -ia $hsap_ref -od $plots_dir -cg #-u | |
mosaik_dir="$HOME/mosaik/bin" | |
build_bin="$mosaik_dir/MosaikBuild" | |
align_bin="$mosaik_dir/MosaikAligner" | |
text_bin="$mosaik_dir/MosaikText" | |
jump_bin="$mosaik_dir/MosaikJump" | |
coverage_bin="$mosaik_dir/MosaikCoverage" | |
data_dir="/mnt/454" | |
#reads="$data_dir/reads/reads.fna" | |
#quals="$data_dir/reads/qualities.fna" | |
reads="$data_dir/reads/one_region.fna" | |
quals="$data_dir/reads/one_region.fna" | |
reads_bin="$data_dir/reads/one_region_454_hsap_reads.dat" | |
hsap_ref="$HOME/mosaik/hsap/full_hsap.dat" | |
cpus=8 | |
jump_database="$HOME/mosaik/hsap/hsap_jump_15" | |
a_out_bin="$data_dir/mapping_out/hsap_aligned.dat" | |
hash_size=15 | |
plots_dir="$data_dir/plots" | |
# 1. Build ref | |
build_ref() | |
{ | |
$build_bin -fr full_hsap.fa -oa full_hsap.dat | |
} | |
# 2. Convert reads | |
convert_reads() | |
{ | |
$build_bin -fr $reads -fq $quals -out $reads_bin -st 454 | |
} | |
# 3. create the jump database (will keep the keys file in memory) | |
create_jump() | |
{ | |
$jump_bin -ia $hsap_ref -out $jump_database -hs $hash_size -km | |
} | |
# 4. Align the reads | |
align() | |
{ | |
$align_bin \ | |
-in $reads_bin \ | |
-out $a_out_bin \ | |
-ia $hsap_ref \ | |
-hs $hash_size \ | |
-mmp .05 \ | |
-a all \ | |
-m all \ | |
-mhp 100 \ | |
-act 26 \ | |
-j $jump_database \ | |
-km -pm \ | |
-p $cpus | |
} | |
# 5. extract mapping info to screen | |
to_screen() | |
{ | |
$text_bin -in $a_out_bin -screen # -u | |
} | |
# report coverage | |
plots() | |
{ | |
mkdir -p $plots_dir | |
$coverage_bin -in $a_out_bin -ia $hsap_ref -od $plots_dir -cg #-u | |
} | |
plots | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment