Usage

The getNumReads script reads all files in the working directory with regular expression *.bam, and for each bam file, prints the file name, the count for all reads in the file, and the count for all mapped reads in the file. getNumReads uses the script samtools. More information on samtools can be found here.


Command Line:

getNumReads is called with the following command line prompt:

$ getNumReads


Example:

Running getNumReads with the following command line prompt:

$ getNumReads


In a directory that contains the following files:

Bp0071_2_S90-bowtie2.bam
Bp7709_S66-bowtie2.bam
Bp8815_S143-bowtie2.bam


Will produce the following results in the command line:

Bp0071_2_S90-bowtie2    203096    170848
Bp7709_S66-bowtie2      112288    2099
Bp8815_S143-bowtie2     168658    39010