Quantcast

Documentation Center

  • Trial Software
  • Product Updates

bowtie

Map short reads to reference sequence using Burrows-Wheeler transform

Syntax

  • bowtie(indexBaseName,reads,outputFileName) example
  • bowtie(indexBaseName,reads,outputFileName,Name,Value)

Description

example

bowtie(indexBaseName,reads,outputFileName) aligns the reads specified in reads to the indexed reference specified by indexBaseName, and writes the results to the BAM-formatted file outputFileName.

    Note:   bowtie runs on Mac and UNIX® platforms only.

bowtie(indexBaseName,reads,outputFileName,Name,Value) aligns reads using additional options specified by one or more name-value pair arguments.

Examples

expand all

Align Short Reads

Download the E. coli genome from NCBI.

getgenbank('NC_008253','tofile','NC_008253.fna','SequenceOnly',true)

Built a Bowtie index with the base name ECOLI.

bowtiebuild('NC_008253.fna','ECOLI')

Find the path to the example FASTQ file ecoli100.fq, which has E. Coli short reads.

fastqfile = which('ecoli100.fq')

Align the short reads in ecoli100.fq to the built index with base name ECOLI.

bowtie('ECOLI',fastqfile,'ecoli100.bam')

Access the mapped reads using BioMap.

bm = BioMap('ecoli100.bam')
bm = 

BioMap with properties:

    SequenceDictionary: {'gi|110640213|ref|NC_008253.1|'}
             Reference: [73x1 File indexed property]
             Signature: [73x1 File indexed property]
                 Start: [73x1 File indexed property]
        MappingQuality: [73x1 File indexed property]
                  Flag: [73x1 File indexed property]
          MatePosition: [73x1 File indexed property]
               Quality: [73x1 File indexed property]
              Sequence: [73x1 File indexed property]
                Header: [73x1 File indexed property]
                 NSeqs: 73
                  Name: ''

Input Arguments

expand all

indexBaseName — Name of indexed reference filestring

Name of indexed reference file for short read alignment, specified as a string containing the path and base name of the Bowtie index file.

reads — Short reads to alignstring | cell array of strings

Short reads to align to the indexed reference, specified as a string or cell array of strings indicating one or more FASTQ formatted files with the input reads.

outputFileName — Name for output filestring

Name for output file containing the results of the short read alignment, specified as a string. By default, the output file is BAM-formatted, and bowtie automatically adds the .bam extension if it is missing from the file name.

To specify a SAM-formatted output file, use the name-value pair argument BamFileOutput,false. In this case, bowtie automatically adds the .sam extension if it is missing from the file name.

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

Example: 'BamFileOutput',false,'Paired',true specifies the output file is SAM-formatted, and bowtie performs pair-read alignment.

'BamFileOutput' — Indicator for output file formattrue (default) | false

Indicator for the output file format, specified as the comma-separated pair consisting of 'BamFileOutput' and either true or false.

  • If true (the default), then the output file is BAM-formatted, with a .bam extension.

  • If false, then the output file is SAM-formatted, with a .sam extension.

bowtie automatically adds the corresponding file extension if it is missing from the input argument outputFileName.

Example: 'BamFileOutput',false

Data Types: logical

'Paired' — Indicator for paired-read alignment performancefalse (default) | true

Indicator for paired-read alignment performance, specified as the comma-separated pair consisting of 'Paired' and either true or false (the default). If false, then bowtie performs paired-read alignment using the odd elements in reads as the upstream mates and the even elements in reads as the downstream mates.

Example: 'Paired',true

Data Types: logical

'BowtieOptions' — Additional bowtie optionsvalid bowtie option

Additional bowtie options, specified as the comma-separated pair consisting of 'BowtieOptions' and any valid bowtie option. Type bowtie('--help') for available options.

Example: 'BowtieOptions','-k 5'

More About

expand all

Tips

See Also

| | | | | |

Was this topic helpful?