bpp-seq3
3.0.0
|
A event-driven CoreSymbolList object. More...
#include <Bpp/Seq/CoreSymbolList.h>
Public Member Functions | |
virtual | ~EdCoreSymbolList () |
virtual double | getStateValueAt (size_t siteIndex, int state) const |
From CruxSymbolList. More... | |
virtual double | operator() (size_t siteIndex, int state) const |
virtual const Alphabet * | getAlphabet () const =0 |
Get the alphabet associated to the list. More... | |
virtual size_t | size () const =0 |
Get the number of elements in the list. More... | |
virtual std::string | toString () const =0 |
Convert the list as a string. More... | |
The Clonable interface | |
virtual EdCoreSymbolList * | clone () const =0 |
Acting on the content of the list. | |
virtual void | setContent (const std::vector< T > &list)=0 |
Set the whole content of the list. More... | |
virtual const std::vector< T > & | getContent () const =0 |
Edition methods. | |
virtual void | addElement (const T &c)=0 |
Add a character to the end of the list. More... | |
virtual void | addElement (size_t pos, const T &c)=0 |
Add a character at a certain position in the list. More... | |
virtual void | setElement (size_t pos, const T &c)=0 |
Set the element at position 'pos' to character 'c'. More... | |
virtual const T & | getElement (size_t pos) const =0 |
Get the element at position 'pos' as a character. More... | |
Provide direct access to the list content. | |
| |
virtual const T & | getValue (size_t pos) const =0 |
checked access to a character in list. More... | |
virtual const T & | operator[] (size_t pos) const =0 |
Operator [] overloaded for quick access to a character in list. More... | |
virtual T & | operator[] (size_t pos)=0 |
Operator [] overloaded for quick access to a character in list. More... | |
Edition methods. | |
virtual void | deleteElement (size_t pos)=0 |
Remove the element at position 'pos'. More... | |
virtual void | deleteElements (size_t pos, size_t len)=0 |
Remove the elements at position 'pos'. More... | |
Provide direct access to the list content. | |
| |
virtual void | shuffle ()=0 |
Randomly shuffle the content of the list, with linear complexity. More... | |
Protected Member Functions | |
virtual void | propagateEvents (bool yn)=0 |
virtual bool | propagateEvents () const =0 |
A event-driven CoreSymbolList object.
This is a general purpose container, containing an ordered list of states(= letters). The states that allowed to be present in the list are defined by an alphabet object, which is passed to the list constructor by a pointer.
For programming convenience, the states are stored as Ts, but the translation toward and from a char description is easily performed with the Alphabet classes.
Definition at line 395 of file CoreSymbolList.h.
|
inlinevirtual |
Definition at line 408 of file CoreSymbolList.h.
|
pure virtual |
Implemented in bpp::EdSymbolList< T >.
|
pure virtualinherited |
Add a character to the end of the list.
c | The character to add. |
Implemented in bpp::EdSymbolList< T >, bpp::SymbolList< T >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::AlignedSequenceContainer::addSite(), bpp::SequenceTools::getPutativeHaplotypes(), bpp::AbstractReverseTransliterator::reverse(), and bpp::AbstractTransliterator::translate().
|
pure virtualinherited |
Add a character at a certain position in the list.
pos | The postion where to insert the element. |
c | The character to add. |
Implemented in bpp::EdSymbolList< T >, bpp::SymbolList< T >, and bpp::BasicProbabilisticSymbolList.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
pure virtual |
Implements bpp::CoreSymbolList< T >.
Implemented in bpp::EdSymbolList< T >, bpp::EdSymbolList< int >, bpp::SequenceWithQuality, bpp::SequenceWithAnnotation, and bpp::EdIntSymbolList.
|
pure virtualinherited |
Remove the element at position 'pos'.
pos | The position of the element to remove. |
Implemented in bpp::EdSymbolList< T >, bpp::EdSymbolList< int >, bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::AlignedSequenceContainer::deleteSite(), bpp::SequenceTools::getCDS(), bpp::SequenceTools::removeGaps(), bpp::VectorSiteContainer::removeSequence(), bpp::AlignedSequenceContainer::removeSite(), and bpp::SequenceTools::removeStops().
|
pure virtualinherited |
Remove the elements at position 'pos'.
pos | The position of the first element to remove. |
len | The length of the region to remove. |
Implemented in bpp::EdSymbolList< T >, bpp::EdSymbolList< int >, bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::AlignedSequenceContainer::deleteSites().
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >.
|
pure virtualinherited |
Get the alphabet associated to the list.
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::VectorProbabilisticSequenceContainer::addSequence(), bpp::VectorProbabilisticSiteContainer::addSequence(), bpp::VectorSequenceContainer::addSequence(), bpp::VectorSiteContainer::addSequence(), bpp::CompressedVectorSiteContainer::addSite(), bpp::AlignedSequenceContainer::addSite(), bpp::VectorSiteContainer::addSite(), bpp::SiteContainerTools::alignNW(), bpp::BasicSequence::append(), bpp::SequenceWithAnnotation::append(), bpp::SequenceTools::areSequencesIdentical(), bpp::SymbolListTools::areSymbolListsIdentical(), bpp::SequenceTools::bowkerTest(), bpp::SymbolListTools::changeGapsToUnknownCharacters(), bpp::SymbolListTools::changeUnresolvedCharactersToGaps(), bpp::SequenceTools::combineSequences(), bpp::SequenceTools::complement(), bpp::SiteContainerTools::computeSimilarity(), bpp::SequenceTools::concatenate(), bpp::SequenceWithAnnotationTools::createMaskAnnotation(), bpp::SequenceTools::findFirstOf(), bpp::CodonSiteTools::fixedDifferences(), bpp::CodonSiteTools::generateCodonSiteWithoutRareVariant(), bpp::SequenceTools::getCDS(), bpp::GeneticCode::getCodingSequence(), bpp::SequenceTools::getComplement(), bpp::SymbolListTools::getCounts(), bpp::SymbolListTools::getGCContent(), bpp::SequenceTools::getNumberOfCompleteSites(), bpp::SymbolListTools::getNumberOfDistinctPositions(), bpp::SymbolListTools::getNumberOfPositionsWithoutGap(), bpp::SequenceTools::getNumberOfSites(), bpp::SequenceTools::getNumberOfUnresolvedSites(), bpp::SequenceTools::getPercentIdentity(), bpp::SequenceTools::getPutativeHaplotypes(), bpp::SequenceTools::getSequenceWithCompleteSites(), bpp::SequenceTools::getSequenceWithoutGaps(), bpp::SequenceTools::getSequenceWithoutStops(), bpp::SymbolListTools::hasGap(), bpp::CodonSiteTools::hasGapOrStop(), bpp::CodonSiteTools::hasStop(), bpp::SymbolListTools::hasUnknown(), bpp::SymbolListTools::hasUnresolved(), bpp::SequenceTools::invertComplement(), bpp::SymbolListTools::isComplete(), bpp::SymbolListTools::isConstant(), bpp::SymbolListTools::isGapOnly(), bpp::SymbolListTools::isGapOrUnresolvedOnly(), bpp::CodonSiteTools::isMonoSitePolymorphic(), bpp::CodonSiteTools::isSynonymousPolymorphic(), bpp::SymbolListTools::jointEntropy(), bpp::CodonSiteTools::meanNumberOfSynonymousPositions(), bpp::SymbolListTools::mutualInformation(), bpp::Pasta::nextSequence(), bpp::PhredPoly::nextSequence(), bpp::SymbolListTools::numberOfGaps(), bpp::CodonSiteTools::numberOfNonSynonymousSubstitutions(), bpp::CodonSiteTools::numberOfSubstitutions(), bpp::SymbolListTools::numberOfUnresolved(), bpp::SymbolList< T >::operator=(), bpp::BasicProbabilisticSymbolList::operator=(), bpp::CodonSiteTools::piNonSynonymous(), bpp::CodonSiteTools::piSynonymous(), bpp::SequenceTools::removeGaps(), bpp::SequenceTools::removeStops(), bpp::SequenceTools::replaceStopsWithGaps(), bpp::WordAlphabet::reverse(), bpp::NucleicAcidsReplication::reverse(), bpp::AbstractReverseTransliterator::reverse(), bpp::SequenceTools::reverseTranscript(), bpp::SequenceTools::RNYslice(), bpp::VectorProbabilisticSiteContainer::setSequence(), bpp::VectorProbabilisticSequenceContainer::setSequence(), bpp::VectorSiteContainer::setSequence(), bpp::VectorSequenceContainer::setSequence(), bpp::AlignedSequenceContainer::setSite(), bpp::CompressedVectorSiteContainer::setSite(), bpp::VectorSiteContainer::setSite(), bpp::SequenceTools::subseq(), bpp::SequenceTools::subtractHaplotype(), bpp::SequenceTools::transcript(), bpp::NucleicAcidsReplication::translate(), bpp::AbstractTransliterator::translate(), bpp::WordAlphabet::translate(), bpp::SiteContainerTools::translateAlignment(), bpp::SymbolListTools::variabilityShannon(), and bpp::Pasta::writeSequence().
|
pure virtualinherited |
Implemented in bpp::ProbabilisticSequence, bpp::SymbolList< T >, bpp::SymbolList< int >, bpp::BasicProbabilisticSymbolList, and bpp::BasicProbabilisticSequence.
Referenced by bpp::SequenceWithQualityTools::concatenate(), bpp::SequenceWithQualityTools::invert(), bpp::BasicProbabilisticSymbolList::operator=(), bpp::BasicSequence::operator=(), and bpp::SequenceWithAnnotation::operator=().
|
pure virtualinherited |
Get the element at position 'pos' as a character.
pos | The position of the character to retrieve. |
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
|
pure virtual |
Implemented in bpp::EdSymbolList< T >, and bpp::EdSymbolList< int >.
|
pure virtual |
Implemented in bpp::EdSymbolList< T >, and bpp::EdSymbolList< int >.
|
pure virtual |
Implemented in bpp::EdSymbolList< T >, and bpp::EdSymbolList< int >.
|
inlinevirtual |
From CruxSymbolList.
Reimplemented from bpp::CruxSymbolList.
Definition at line 416 of file CoreSymbolList.h.
References bpp::CruxSymbolList::getStateValueAt().
|
pure virtualinherited |
checked access to a character in list.
pos | The position to retrieve. |
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::VectorSiteContainer::addSequence(), bpp::SequenceTools::combineSequences(), bpp::SequenceTools::complement(), bpp::SequenceTools::findFirstOf(), bpp::SymbolListTools::getGCContent(), bpp::SequenceTools::getPercentIdentity(), bpp::SequenceTools::invert(), bpp::SequenceTools::invertComplement(), bpp::NucleicAcidsReplication::reverse(), bpp::AbstractReverseTransliterator::reverse(), bpp::VectorProbabilisticSiteContainer::setSequence(), bpp::VectorSiteContainer::setSequence(), bpp::SequenceTools::subtractHaplotype(), bpp::NucleicAcidsReplication::translate(), and bpp::AbstractTransliterator::translate().
|
inlinevirtual |
Reimplemented from bpp::CruxSymbolList.
Definition at line 421 of file CoreSymbolList.h.
References bpp::CruxSymbolList::operator()().
|
pure virtualinherited |
Operator [] overloaded for quick access to a character in list.
pos | The position to retrieve. |
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
|
pure virtualinherited |
Operator [] overloaded for quick access to a character in list.
pos | The position to retrieve. |
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >, and bpp::EdSymbolList< int >.
|
protectedpure virtual |
Implemented in bpp::EdSymbolList< T >, and bpp::EdSymbolList< int >.
|
pure virtual |
Implemented in bpp::EdSymbolList< T >.
|
pure virtualinherited |
Set the whole content of the list.
list | The new content of the list. |
Implemented in bpp::EdSymbolList< T >, bpp::SymbolList< T >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::Pasta::nextSequence().
|
pure virtualinherited |
Set the element at position 'pos' to character 'c'.
pos | The position of the character to set. |
c | The value of the element. |
Implemented in bpp::EdSymbolList< T >, bpp::SymbolList< T >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::SequenceTools::complement(), bpp::SequenceTools::invert(), bpp::SequenceTools::invertComplement(), bpp::SequenceTools::replaceStopsWithGaps(), and bpp::AlignedSequenceContainer::setSite().
|
pure virtualinherited |
Randomly shuffle the content of the list, with linear complexity.
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
|
pure virtualinherited |
Get the number of elements in the list.
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, and bpp::BasicProbabilisticSymbolList.
Referenced by bpp::VectorProbabilisticSiteContainer::addSequence(), bpp::AlignedSequenceContainer::addSequence(), bpp::VectorSiteContainer::addSequence(), bpp::CompressedVectorSiteContainer::addSite(), bpp::AlignedSequenceContainer::addSite(), bpp::VectorSiteContainer::addSite(), bpp::AlignedSequenceContainer::AlignedSequenceContainer(), bpp::BasicSequence::append(), bpp::SequenceWithAnnotation::append(), bpp::SequenceTools::areSequencesIdentical(), bpp::SymbolListTools::areSymbolListsIdentical(), bpp::SequenceTools::bowkerTest(), bpp::SymbolListTools::changeGapsToUnknownCharacters(), bpp::SymbolListTools::changeUnresolvedCharactersToGaps(), bpp::AlignedSequenceContainer::checkSize_(), bpp::SequenceTools::combineSequences(), bpp::SequenceTools::complement(), bpp::SiteContainerTools::computeSimilarity(), bpp::SequenceTools::concatenate(), bpp::SequenceWithAnnotationTools::createMaskAnnotation(), bpp::SequenceTools::findFirstOf(), bpp::CodonSiteTools::fixedDifferences(), bpp::CodonSiteTools::generateCodonSiteWithoutRareVariant(), bpp::SiteContainerTools::getAlignmentPositions(), bpp::SequenceTools::getCDS(), bpp::GeneticCode::getCodingSequence(), bpp::SequenceContainerTools::getCodonPosition(), bpp::SymbolListTools::getCounts(), bpp::SequenceContainerTools::getCounts(), bpp::SymbolListTools::getFrequencies(), bpp::SequenceContainerTools::getFrequencies(), bpp::SymbolListTools::getGCContent(), bpp::SymbolListTools::getMajorAllele(), bpp::SymbolListTools::getMajorAlleleFrequency(), bpp::SymbolListTools::getMinorAllele(), bpp::SymbolListTools::getMinorAlleleFrequency(), bpp::SequenceTools::getNumberOfCompleteSites(), bpp::SymbolListTools::getNumberOfDistinctCharacters(), bpp::SymbolListTools::getNumberOfDistinctPositions(), bpp::SymbolListTools::getNumberOfPositionsWithoutGap(), bpp::SequenceTools::getNumberOfSites(), bpp::SequenceTools::getNumberOfUnresolvedSites(), bpp::SequenceTools::getPercentIdentity(), bpp::SequenceTools::getPutativeHaplotypes(), bpp::SiteContainerTools::getSequencePositions(), bpp::SequenceTools::getSequenceWithCompleteSites(), bpp::SequenceTools::getSequenceWithoutGaps(), bpp::SequenceTools::getSequenceWithoutStops(), bpp::CompressedVectorSiteContainer::getSiteIndex_(), bpp::VectorProbabilisticSequenceContainer::getStateValueAt(), bpp::VectorSequenceContainer::getStateValueAt(), bpp::CodonAlphabet::getWord(), bpp::WordAlphabet::getWord(), bpp::SymbolListTools::hasGap(), bpp::CodonSiteTools::hasGapOrStop(), bpp::SimpleSequencePositionIterator::hasMorePositions(), bpp::SymbolListTools::hasSingleton(), bpp::CodonSiteTools::hasStop(), bpp::SymbolListTools::hasUnknown(), bpp::SymbolListTools::hasUnresolved(), bpp::SymbolListTools::heterozygosity(), bpp::SequenceMask::init(), bpp::SequenceQuality::init(), bpp::SequenceTools::invert(), bpp::SequenceTools::invertComplement(), bpp::SymbolListTools::isComplete(), bpp::SymbolListTools::isConstant(), bpp::SymbolListTools::isDoubleton(), bpp::CodonSiteTools::isFourFoldDegenerated(), bpp::SymbolListTools::isGapOnly(), bpp::SymbolListTools::isGapOrUnresolvedOnly(), bpp::CodonSiteTools::isMonoSitePolymorphic(), bpp::SymbolListTools::isParsimonyInformativeSite(), bpp::CodonSiteTools::isSynonymousPolymorphic(), bpp::SymbolListTools::isTriplet(), bpp::SymbolListTools::jointEntropy(), bpp::CodonSiteTools::meanNumberOfSynonymousPositions(), bpp::SymbolListTools::mutualInformation(), bpp::SymbolListTools::numberOfGaps(), bpp::CodonSiteTools::numberOfNonSynonymousSubstitutions(), bpp::CodonSiteTools::numberOfSubstitutions(), bpp::SymbolListTools::numberOfUnresolved(), bpp::SymbolList< T >::operator=(), operator==(), bpp::CodonSiteTools::piNonSynonymous(), bpp::CodonSiteTools::piSynonymous(), bpp::SequenceTools::removeGaps(), bpp::SequenceTools::removeStops(), bpp::SequenceTools::replaceStopsWithGaps(), bpp::SiteContainerTools::resolveDottedAlignment(), bpp::CodonAlphabet::reverse(), bpp::WordAlphabet::reverse(), bpp::NucleicAcidsReplication::reverse(), bpp::AbstractReverseTransliterator::reverse(), bpp::SequenceTools::RNYslice(), bpp::SequenceContainerTools::sequencesHaveTheSameLength(), bpp::SequenceWalker::SequenceWalker(), bpp::VectorProbabilisticSiteContainer::setSequence(), bpp::VectorSiteContainer::setSequence(), bpp::AlignedSequenceContainer::setSequence(), bpp::AlignedSequenceContainer::setSite(), bpp::CompressedVectorSiteContainer::setSite(), bpp::VectorSiteContainer::setSite(), bpp::SequenceTools::subseq(), bpp::SequenceTools::subtractHaplotype(), bpp::SymbolList< T >::SymbolList(), bpp::NucleicAcidsReplication::translate(), bpp::AbstractTransliterator::translate(), bpp::CodonAlphabet::translate(), bpp::WordAlphabet::translate(), bpp::SiteContainerTools::translateAlignment(), bpp::SymbolListTools::variabilityFactorial(), bpp::SymbolListTools::variabilityShannon(), bpp::Phylip::writeInterleaved(), bpp::Fasta::writeSequence(), bpp::Pasta::writeSequence(), and bpp::Phylip::writeSequential().
|
pure virtualinherited |
Convert the list as a string.
This method is useful for dumping a list to a file or to the screen for display.
Implemented in bpp::SymbolList< T >, bpp::SymbolList< int >, bpp::BasicSequence, bpp::BasicProbabilisticSymbolList, bpp::EdIntSymbolList, and bpp::BasicIntSymbolList.
Referenced by bpp::SequenceWithAnnotationTools::createMaskAnnotation(), bpp::AbstractProbabilisticSequenceContainer::toString(), bpp::AbstractSequenceContainer::toString(), bpp::VectorProbabilisticSequenceContainer::toString(), bpp::Clustal::writeAlignment(), and bpp::Stockholm::writeAlignment().