Advertisement
ProzacR

miraligner notes 200107

Jan 7th, 2020
430
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.01 KB | None | 0 0
  1. for file in *ds.*; do data=$(echo $file | cut -d"_" -f1) && mkdir $data; done
  2. for file in *ds.*; do data=$(echo $file | cut -d"_" -f1) && mv $file/*.fastq $data; done
  3. rmdir *
  4. for file in */; do cd $file && cat *.fastq > ${file%/}.fastq && cd ..; done
  5. for file in */; do echo -n "${file}, " && grep "@" $file${file%/}.fastq | wc -l; done > number_of_reads.csv
  6. #tie visi su fastq folderiai i atskira folderi fastq geriausia tada ~, bet pataisyti:
  7. for file in */; do echo -n "${file}, " && grep "@" $file${file%/}_clipped.fastq | wc -l; done > number_of_reads_clipped.csv && for file in */; do cd $file && fastq2fasta.pl ${file%/}_clipped.fastq > ${file%/}_reads.fa && collapse_reads_md.pl ${file%/}_reads.fa seq > ../reads_colapsed/${file%/}_reads_colapsed.fa && cd ..; done
  8. for file in *_reads_colapsed.fa; do java -jar -Xms8g -Xmx200g /tools/seqbuster/miraligner/miraligner-3.2/miraligner.jar -sub 1 -trim 3 -add 3 -s hsa -i $file -db /data/databases_2019-10-23/hsa -o "${file%_reads_colapsed.fa}_aligner_output" -freq; done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement