seqconsensus
Calculate consensus sequence
Syntax
CSeq
= seqconsensus(Seqs
)
[CSeq
, Score
]
= seqconsensus(Seqs
)
CSeq
= seqconsensus(Profile
)
seqconsensus(..., 'PropertyName
', PropertyValue
,...)
seqconsensus(..., 'ScoringMatrix', ScoringMatrixValue
)
Arguments
Seqs | Set of multiply aligned amino acid or nucleotide sequences. Enter a character array, string
vector, cell array of character vectors, or an array of structures with the field
Sequence . |
Profile | Sequence profile. Enter a profile from the function seqprofile . Profile is
a matrix of size [20 (or 4) x Sequence Length] with
the frequency or count of amino acids (or nucleotides) for every position. Profile can
also have 21 (or 5) rows if gaps are included in the consensus. |
ScoringMatrixValue | Either of the following:
Note If you need to compile |
Description
,
for a multiply aligned set of sequences (CSeq
= seqconsensus(Seqs
)Seqs
),
returns a character vector with the consensus sequence (CSeq
).
The frequency of symbols (20
amino acids, 4
nucleotides)
in the set of sequences is determined with the function seqprofile
. For ambiguous nucleotide
or amino acid symbols, the frequency or count is added to the standard
set of symbols.
[
returns
the conservation score of the consensus sequence. Scores are computed
with the scoring matrix CSeq
, Score
]
= seqconsensus(Seqs
)BLOSUM50
for amino acids
or NUC44
for nucleotides. Scores are the average
euclidean distance between the scored symbol and the M-dimensional
consensus value. M
is the size of the alphabet.
The consensus value is the profile weighted by the scoring matrix.
returns
a character vector with the consensus sequence (CSeq
= seqconsensus(Profile
)CSeq
)
from a sequence profile (Profile
).
seqconsensus(..., '
defines
optional properties using property name/value pairs.PropertyName
', PropertyValue
,...)
seqconsensus(..., 'ScoringMatrix',
specifies
the scoring matrix. ScoringMatrixValue
)
The following input parameters are analogous to the function seqprofile
when the alphabet is restricted
to 'AA'
or 'NT'
.
seqconsensus(..., 'Alphabet',
AlphabetValue
)
seqconsensus(..., 'Gaps',
GapsValue
)
seqconsensus(..., 'Ambiguous',
AmbiguousValue
)
seqconsensus(..., 'Limits',
LimitsValue
)
Examples
seqs = fastaread('pf00002.fa'); [C,S] = seqconsensus(seqs,'limits',[50 60],'gaps','all')
Version History
Introduced before R2006a
See Also
fastaread
| multialignread
| multialignwrite
| profalign
| seqdisp
| seqprofile