Main Content

baselookup

Find nucleotide codes, integers, names, and complements

Syntax

baselookup
baselookup('Complement', SeqNT)
baselookup('Code', CodeValue)
baselookup('Integer', IntegerValue)
baselookup('Name', NameValue)

Arguments

SeqNT

Nucleotide sequence(s) represented by one of the following:

  • Character vector or string containing single-letter codes from the table Nucleotide Lookup

  • Cell array of sequences

  • Two-dimensional character array of sequences

Note

If the input is multiple sequences, the complement for each sequence is determined independently.

CodeValue

Nucleotide letter code represented by one of the following:

  • Character vector or string specifying a single-letter code representing a nucleotide. For valid single-letter codes, see the table Nucleotide Lookup.

  • Cell array of letter codes.

  • Two-dimensional character array of letter codes.

IntegerValue Single integer representing a nucleotide. For valid integers, see the table Nucleotide Lookup.
NameValue

Nucleotide name represented by one of the following:

  • Character vector or string specifying a nucleotide name. For valid nucleotide names, see the table Nucleotide Lookup.

  • Cell array of names.

  • Two-dimensional character array of names.

Description

baselookup displays a table of nucleotide codes, integers, names, and complements.

Nucleotide Lookup

CodeInteger Nucleotide Name MeaningComplement
A 1Adenine AT
C 2CytosineCG
G 3GuanineGC
T 4ThymineTA
U4UracilUA
R 5PurineA or GY
Y 6PyrimidineC or TR
K 7KetoG or T M
M 8AminoA or CK
S 9Strong interaction (3 H bonds)C or GS
W 10Weak interaction (2 H bonds)A or TW
B 11Not AC or G or T V
D 12Not CA or G or TH
H 13Not GA or C or TD
V 14Not T or UA or C or GB
N, X 15Any nucleotideA or C or G or T or UN
- 16Gap of indeterminate lengthGap-

baselookup('Complement', SeqNT) displays the complementary nucleotide sequence.

baselookup('Code', CodeValue) displays the corresponding meaning and nucleotide name. For ambiguous nucleotide codes (R, Y, K, M, S, W, B, D, H, V, N, and X), the nucleotide name is a descriptive name.

baselookup('Integer', IntegerValue) displays the corresponding letter code, meaning, and nucleotide name.

baselookup('Name', NameValue) displays the corresponding letter code, meaning, and nucleotide name or descriptive name.

Examples

collapse all

baselookup('Complement', 'TAGCTGRCCAAGGCCAAGCGAGCTTN')
ans = 
    'ATCGACYGGTTCCGGTTCGCTCGAAN
     '

Display the meaning and nucleotide name or descriptive name for the nucleotide codes G and Y.

baselookup('Code', 'G')
ans = 
    'G	Guanine
     '

baselookup('Code', 'Y')
ans = 
    'T|C	pYrimidine
     '

Display the nucleotide letter code, meaning, and nucleotide name or descriptive name for the integers 1 and 7.

baselookup('Integer', 1)
ans = 
    'A	A - Adenine
     '

baselookup('Integer', 7)
ans = 
    'K	G|T - Keto
     '

Display the corresponding nucleotide letter code, meaning, and name for cytosine and purine.

baselookup('Name','cytosine')
ans = 
    'C	C - Cytosine
     '

baselookup('Name','purine')
ans = 
    'R	G|A - puRine
     '

Introduced before R2006a