Main Content


Display open reading frames in sequence


seqshoworfs(SeqNT, ...'Frames', FramesValue, ...)
seqshoworfs(SeqNT, ...'GeneticCode', GeneticCodeValue, ...)
seqshoworfs(SeqNT, ...'MinimumLength', MinimumLengthValue, ...)
seqshoworfs(SeqNT, ...'AlternativeStartCodons', AlternativeStartCodonsValue, ...)
seqshoworfs(SeqNT, ...'Color', ColorValue, ...)
seqshoworfs(SeqNT, ...'Columns', ColumnsValue, ...)



Nucleotide sequence. Enter either a character vector or string with A, T (U), G, C, and ambiguous characters R, Y, K, M, S, W, B, D, H, V, N, or a vector of integers. You can also enter a structure with the field Sequence.


Property to select the frame. Enter 1, 2, 3, -1, -2, -3, enter a vector with integers, or 'all'. The default value is the vector [1 2 3]. Frames -1, -2, and -3 correspond to the first, second, and third reading frames for the reverse complement.


Genetic code name. Enter a code number or a code name from the table Genetic Code.


Property to set the minimum number of codons in an ORF.


Property to control using alternative start codons. Enter either true or false. The default value is false.


Color to highlight the reading frame. Specify one of the following:

  • Three-element numeric vector of RGB values

  • Character vector or string containing a predefined single-letter color code

  • Character vector or string containing a predefined color name

For example, to use cyan, enter [0 1 1], 'c', or 'cyan'. For more information on specifying colors, see Color Options.

To specify different colors for the three reading frames, use a 1-by-3 cell array of color values. If you are displaying reverse complement reading frames, then use a 1-by-6 cell array of color values.

The default color scheme is blue for the first reading frame, red for the second, and green for the third.


Property to specify the number of columns in the output.

Genetic Code

Code NumberCode Name
2Vertebrate Mitochondrial
3Yeast Mitochondrial
4Mold, Protozoan, Coelenterate Mitochondrial, and Mycoplasma/Spiroplasma
5Invertebrate Mitochondrial
6Ciliate, Dasycladacean, and Hexamita Nuclear
9Echinoderm Mitochondrial
10Euplotid Nuclear
11Bacterial and Plant Plastid
12Alternative Yeast Nuclear
13Ascidian Mitochondrial
14Flatworm Mitochondrial
15Blepharisma Nuclear
16Chlorophycean Mitochondrial
21Trematode Mitochondrial
22Scenedesmus Obliquus Mitochondrial
23Thraustochytrium Mitochondrial


seqshoworfs identifies and highlights all open reading frames using the standard or an alternative genetic code.

seqshoworfs(SeqNT) displays the sequence with all open reading frames highlighted, and it returns a structure of start and stop positions for each ORF in each reading frame. The standard genetic code is used with start codon 'AUG' and stop codons 'UAA', 'UAG', and 'UGA'.

seqshoworfs(SeqNT, ...'PropertyName', PropertyValue, ...) calls seqshoworfs with optional properties that use property name/property value pairs. You can specify one or more properties in any order. Each PropertyName must be enclosed in single quotes and is case insensitive. These property name/property value pairs are as follows:

seqshoworfs(SeqNT, ...'Frames', FramesValue, ...) specifies the reading frames to display. The default is to display the first, second, and third reading frames with ORFs highlighted in each frame.

seqshoworfs(SeqNT, ...'GeneticCode', GeneticCodeValue, ...) specifies the genetic code to use for finding open reading frames.

seqshoworfs(SeqNT, ...'MinimumLength', MinimumLengthValue, ...) sets the minimum number of codons for an ORF to be considered valid. The default value is 10.

seqshoworfs(SeqNT, ...'AlternativeStartCodons', AlternativeStartCodonsValue, ...) uses alternative start codons if AlternativeStartCodons is set to true. For example, in the human mitochondrial genetic code, AUA and AUU are known to be alternative start codons. For more details on alternative start codons, see

seqshoworfs(SeqNT, ...'Color', ColorValue, ...) specifies the color used to highlight the open reading frames in the output display. The default color scheme is blue for the first reading frame, red for the second, and green for the third.

seqshoworfs(SeqNT, ...'Columns', ColumnsValue, ...) specifies how many columns per line to use in the output. The default value is 64.


Display the open reading frames in a random nucleotide sequence.

s = randseq(200, 'alphabet', 'dna');

Display the open reading frames in a GenBank® sequence.

HLA_DQB1 = getgenbank('NM_002123');

More About

collapse all

Color Options

The following lists the predefined colors and their RGB triplet equivalents. The short names and long names are character vectors that specify one of eight preset colors. The RGB triplet is a three-element row vector whose elements specify the intensities of the red, green, and blue components of the color; the intensities must be in the range [0 1].

RGB Triplet

Short Name

Long Name

[1 1 0]



[1 0 1]



[0 1 1]



[1 0 0]



[0 1 0]



[0 0 1]



[1 1 1]



[0 0 0]



Version History

Introduced before R2006a