Changes between Version 28 and Version 29 of SOPs/miningSAMBAM


Ignore:
Timestamp:
07/17/15 12:59:34 (10 years ago)
Author:
yhuang
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • SOPs/miningSAMBAM

    v28 v29  
    9090bam_stat.py -i mapped_reads.bam >& bam_stat.out.txt
    9191}}}
     92
     93=== Get only uniquely mapped reads from sam/bam files generated by bowtie2 ===
     94
     95{{{
     96# For sam files:
     97grep -v "XS:i" | grep "AS:i" foo.sam >| foo_uniquely_mapped.sam
     98# For bam files:
     99samtools view -h  foo.bam |grep -E -v "XS:i"|grep -E "@|AS:i" |samtools view -b - >| foo_uniquely_mapped.bam
     100}}}
     101
    92102
    93103=== View alignment with samtools ===