Skip to content

Instantly share code, notes, and snippets.

@CnrLwlss
Created June 30, 2013 14:09
Show Gist options
  • Save CnrLwlss/5895260 to your computer and use it in GitHub Desktop.
Save CnrLwlss/5895260 to your computer and use it in GitHub Desktop.
#!/bin/bash
echo Generating consensus sequences
export PATH=$PATH:/home/username/bowtie2-2.1.0:/home/username/samtools:/home/username/samtools/bcftools:/home/username/samtools/misc
roots=(
SN7640178_10172_8183
SN7640178_10173_8265
SN7640178_10174_8266
SN7640178_10175_8267
)
for x in ${roots[@]}; do
echo Piling up ${x}
samtools mpileup -uf reference_SGD/S288C_reference_genome_R64-1-1_20110203/S288C_reference_sequence_R64-1-1_20110203.fsa alignments/"$x"_sorted.bam.bam | bcftools view -cg - | vcfutils.pl vcf2fq > pileups/"$x"_cons.fq&
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment