bpp-seq3  3.0.0
bpp::ProbabilisticSite Class Referenceabstract

#include <Bpp/Seq/ProbabilisticSite.h>

+ Inheritance diagram for bpp::ProbabilisticSite:
+ Collaboration diagram for bpp::ProbabilisticSite:

Public Types

typedef std::vector< double > SymbolType
 
typedef Table< double > DTable
 

Public Member Functions

 ProbabilisticSite (std::shared_ptr< const Alphabet > &alpha)
 Build a new void ProbabilisticSite object with the specified alphabet. More...
 
 ProbabilisticSite (std::shared_ptr< const Alphabet > &alpha, int position)
 Build a new void ProbabilisticSite object with the specified alphabet and position. More...
 
 ProbabilisticSite (const Table< double > &site, std::shared_ptr< const Alphabet > &alpha)
 Build a new ProbabilisticSite object with the specified alphabet. The content of the site is initialized from a Table<double> object. More...
 
 ProbabilisticSite (const Table< double > &site, std::shared_ptr< const Alphabet > &alpha, int position)
 Build a new ProbabilisticSite object with the specified alphabet and position. The content of the probabilistic site is initialized from a Table<double> object. More...
 
 ProbabilisticSite (const ProbabilisticSite &site)
 The copy constructor. More...
 
 ProbabilisticSite (const ProbabilisticSiteInterface &site)
 
ProbabilisticSiteoperator= (const ProbabilisticSite &site)
 The assignment operator. More...
 
ProbabilisticSiteoperator= (const ProbabilisticSiteInterface &site)
 
virtual ~ProbabilisticSite ()
 
double getStateValueAt (size_t sequencePosition, int state) const
 get value of a state at a position More...
 
virtual std::shared_ptr< const AlphabetgetAlphabet () const =0
 Get the alphabet associated to the list. More...
 
virtual const Alphabetalphabet () 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...
 
virtual double operator() (size_t position, int state) const =0
 get value of a state at a position More...
 
virtual const DTablegetTable () const =0
 
virtual void setContent (const DTable &list)=0
 
virtual void setContent (const std::vector< T > &list)=0
 Set the whole content of the list. More...
 
int getCoordinate () const override
 Get the coordinate associated to this site. More...
 
void setCoordinate (int coordinate) override
 Set the position of this site. More...
 
std::shared_ptr< const AlphabetgetAlphabet () const override
 Get the alphabet associated to the list. More...
 
const Alphabetalphabet () const override
 Get the alphabet associated to the list. More...
 
size_t size () const override
 Get the number of elements in the list. More...
 
void setContent (const std::vector< std::vector< double >> &list) override
 
void setContent (const DTable &list) override
 
std::string toString () const override
 Convert the list as a string. More...
 
void addElement (const std::vector< double > &element) override
 
void addElement (size_t pos, const std::vector< double > &element) override
 
void setElement (size_t pos, const std::vector< double > &element) override
 
const std::vector< double > & getElement (size_t pos) const override
 Get the element at position 'pos' as a character. More...
 
virtual void deleteElement (size_t pos) override
 Remove the element at position 'pos'. More...
 
virtual void deleteElements (size_t pos, size_t len) override
 Remove the elements at position 'pos'. More...
 
const std::vector< std::vector< double > > & getContent () const override
 
const DTablegetTable () const override
 
const std::vector< double > & getValue (size_t pos) const override
 checked access to a character in list. More...
 
const std::vector< double > & operator[] (size_t pos) const override
 Operator [] overloaded for quick access to a character in list. More...
 
std::vector< double > & operator[] (size_t pos) override
 Operator [] overloaded for quick access to a character in list. More...
 
double operator() (size_t siteIndex, int state) const override
 get value of a state at a position More...
 
void shuffle () override
 Randomly shuffle the content of the list, with linear complexity. More...
 
The Clonable interface
ProbabilisticSiteclone () const
 
Setting/getting the position of the site.
virtual int getCoordinate () const =0
 Get the coordinate associated to this site. More...
 
virtual void setCoordinate (int coordinate)=0
 Set the position of this site. 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.
Warning
These operators allow you to modify the list content. No alphabet checking is performed for your modifications, so use with care, or consider using the setContent() method.
virtual void shuffle ()=0
 Randomly shuffle the content of the list, with linear complexity. More...
 
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.
Warning
These operators allow you to modify the list content. No alphabet checking is performed for your modifications, so use with care, or consider using the setContent() method.
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...
 

Protected Attributes

DTable content_
 The list content. More...
 

Private Attributes

int coordinate_
 The position associated with this site. More...
 
std::shared_ptr< const Alphabetalphabet_
 The Alphabet attribute must be initialized in the constructor and then can never be changed. More...
 

Detailed Description

Definition at line 35 of file ProbabilisticSite.h.

Member Typedef Documentation

◆ DTable

Definition at line 35 of file ProbabilisticSymbolList.h.

◆ SymbolType

typedef std::vector<double> bpp::ProbabilisticSymbolListInterface::SymbolType
inherited

Definition at line 34 of file ProbabilisticSymbolList.h.

Constructor & Destructor Documentation

◆ ProbabilisticSite() [1/6]

bpp::ProbabilisticSite::ProbabilisticSite ( std::shared_ptr< const Alphabet > &  alpha)
inline

Build a new void ProbabilisticSite object with the specified alphabet.

Parameters
alphaThe alphabet to use.

Definition at line 46 of file ProbabilisticSite.h.

Referenced by clone().

◆ ProbabilisticSite() [2/6]

bpp::ProbabilisticSite::ProbabilisticSite ( std::shared_ptr< const Alphabet > &  alpha,
int  position 
)
inline

Build a new void ProbabilisticSite object with the specified alphabet and position.

Parameters
alphaThe alphabet to use.
positionThe position attribute for this probabilistic site.

Definition at line 58 of file ProbabilisticSite.h.

◆ ProbabilisticSite() [3/6]

bpp::ProbabilisticSite::ProbabilisticSite ( const Table< double > &  site,
std::shared_ptr< const Alphabet > &  alpha 
)
inline

Build a new ProbabilisticSite object with the specified alphabet. The content of the site is initialized from a Table<double> object.

Parameters
siteThe content of the probabilist site.
alphaThe alphabet to use.
Exceptions
ExceptionIf the content does not match the specified alphabet or is internally inconsistent.

Definition at line 72 of file ProbabilisticSite.h.

◆ ProbabilisticSite() [4/6]

bpp::ProbabilisticSite::ProbabilisticSite ( const Table< double > &  site,
std::shared_ptr< const Alphabet > &  alpha,
int  position 
)
inline

Build a new ProbabilisticSite object with the specified alphabet and position. The content of the probabilistic site is initialized from a Table<double> object.

Parameters
siteThe content of the probabilistic site.
alphaThe alphabet to use.
positionThe position attribute for this site.
Exceptions
ExceptionIf the content does not match the specified alphabet or is internally insconsistent.

Definition at line 87 of file ProbabilisticSite.h.

◆ ProbabilisticSite() [5/6]

bpp::ProbabilisticSite::ProbabilisticSite ( const ProbabilisticSite site)
inline

The copy constructor.

Definition at line 96 of file ProbabilisticSite.h.

◆ ProbabilisticSite() [6/6]

bpp::ProbabilisticSite::ProbabilisticSite ( const ProbabilisticSiteInterface site)
inline

Definition at line 102 of file ProbabilisticSite.h.

◆ ~ProbabilisticSite()

virtual bpp::ProbabilisticSite::~ProbabilisticSite ( )
inlinevirtual

Definition at line 137 of file ProbabilisticSite.h.

Member Function Documentation

◆ addElement() [1/4]

void ProbabilisticSymbolList::addElement ( const std::vector< double > &  element)
overrideinherited

◆ addElement() [2/4]

template<class T >
virtual void bpp::TemplateCoreSymbolListInterface< T >::addElement ( const T &  c)
pure virtualinherited

Add a character to the end of the list.

Parameters
cThe character to add.

Implemented in bpp::AbstractTemplateEventDrivenSymbolList< T >, and bpp::AbstractTemplateSymbolList< T >.

◆ addElement() [3/4]

void ProbabilisticSymbolList::addElement ( size_t  pos,
const std::vector< double > &  element 
)
overrideinherited

◆ addElement() [4/4]

template<class T >
virtual void bpp::TemplateCoreSymbolListInterface< T >::addElement ( size_t  pos,
const T &  c 
)
pure virtualinherited

Add a character at a certain position in the list.

Parameters
posThe position where to insert the element.
cThe character to add.

Implemented in bpp::AbstractTemplateEventDrivenSymbolList< T >, and bpp::AbstractTemplateSymbolList< T >.

◆ alphabet() [1/2]

◆ alphabet() [2/2]

const Alphabet& bpp::ProbabilisticSymbolList::alphabet ( ) const
inlineoverridevirtualinherited

Get the alphabet associated to the list.

Returns
A const reference to the alphabet.
See also
Alphabet class.

Implements bpp::CruxSymbolListInterface.

Definition at line 144 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::alphabet_.

◆ clone()

ProbabilisticSite* bpp::ProbabilisticSite::clone ( ) const
inlinevirtual

Implements bpp::ProbabilisticSiteInterface.

Definition at line 130 of file ProbabilisticSite.h.

References ProbabilisticSite().

◆ deleteElement() [1/2]

virtual void bpp::ProbabilisticSymbolList::deleteElement ( size_t  pos)
inlineoverridevirtualinherited

Remove the element at position 'pos'.

Parameters
posThe position of the element to remove.

Implements bpp::CruxSymbolListInterface.

Definition at line 172 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, and bpp::Table< class >::deleteColumn().

◆ deleteElement() [2/2]

virtual void bpp::CruxSymbolListInterface::deleteElement ( size_t  pos)
pure virtualinherited

◆ deleteElements() [1/2]

virtual void bpp::ProbabilisticSymbolList::deleteElements ( size_t  pos,
size_t  len 
)
inlineoverridevirtualinherited

Remove the elements at position 'pos'.

Parameters
posThe position of the first element to remove.
lenThe length of the region to remove.

Implements bpp::CruxSymbolListInterface.

Definition at line 177 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, and bpp::Table< class >::deleteColumns().

◆ deleteElements() [2/2]

virtual void bpp::CruxSymbolListInterface::deleteElements ( size_t  pos,
size_t  len 
)
pure virtualinherited

Remove the elements at position 'pos'.

Parameters
posThe position of the first element to remove.
lenThe length of the region to remove.

Implemented in bpp::AbstractTemplateEventDrivenSymbolList< T >, bpp::AbstractTemplateEventDrivenSymbolList< int >, bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

◆ getAlphabet() [1/2]

virtual std::shared_ptr<const Alphabet> bpp::CruxSymbolListInterface::getAlphabet ( ) const
pure virtualinherited

Get the alphabet associated to the list.

Returns
A const pointer to the alphabet.
See also
Alphabet class.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

Referenced by bpp::Sequence::append(), bpp::SequenceWithAnnotation::append(), bpp::SequenceTools::areSequencesIdentical(), bpp::SymbolListTools::areSymbolListsIdentical(), bpp::SequenceTools::bowkerTest(), bpp::SymbolListTools::changeGapsToUnknownCharacters(), bpp::SymbolListTools::changeUnresolvedCharactersToGaps(), bpp::SequenceTools::combineSequences(), bpp::SequenceWithQualityTools::complement(), bpp::SequenceTools::complement(), bpp::SiteContainerTools::computeSimilarity(), bpp::SequenceTools::concatenate(), bpp::SequenceWithQualityTools::concatenate(), bpp::SequenceTools::findFirstOf(), bpp::SequenceTools::getCDS(), bpp::SequenceTools::getComplement(), bpp::SymbolListTools::getCountsResolveUnknowns(), bpp::SymbolListTools::getGCContent(), bpp::SymbolListTools::getNumberOfDistinctPositions(), bpp::SymbolListTools::getNumberOfPositionsWithoutGap(), bpp::SequenceTools::getNumberOfUnresolvedSites(), bpp::SequenceTools::getPercentIdentity(), bpp::SequenceTools::getPutativeHaplotypes(), bpp::SequenceTools::getSequenceWithoutGaps(), bpp::SequenceTools::getSequenceWithoutStops(), bpp::SymbolListTools::hasGap(), bpp::SymbolListTools::hasUnknown(), bpp::SymbolListTools::hasUnresolved(), bpp::SequenceTools::invertComplement(), bpp::SymbolListTools::isComplete(), bpp::SymbolListTools::isConstant(), bpp::SymbolListTools::isGapOnly(), bpp::SymbolListTools::isGapOrUnresolvedOnly(), bpp::SymbolListTools::jointEntropy(), bpp::SequenceWithAnnotation::merge(), bpp::SymbolListTools::mutualInformation(), bpp::SymbolListTools::numberOfGaps(), bpp::SymbolListTools::numberOfUnresolved(), bpp::ProbabilisticSymbolList::operator=(), bpp::AbstractTemplateSymbolList< T >::operator=(), bpp::SequenceWithQualityTools::removeGaps(), bpp::SequenceTools::removeGaps(), bpp::SequenceTools::removeStops(), bpp::SequenceTools::replaceStopsWithGaps(), bpp::WordAlphabet::reverse(), bpp::NucleicAcidsReplication::reverse(), bpp::SequenceWithQualityTools::reverseTranscript(), bpp::SequenceTools::RNYslice(), bpp::SequenceTools::subseq(), bpp::SequenceWithQualityTools::subseq(), bpp::SequenceTools::subtractHaplotype(), bpp::SequenceWithQualityTools::transcript(), bpp::NucleicAcidsReplication::translate(), bpp::AbstractTransliterator::translate(), bpp::WordAlphabet::translate(), and bpp::SymbolListTools::variabilityShannon().

◆ getAlphabet() [2/2]

std::shared_ptr<const Alphabet> bpp::ProbabilisticSymbolList::getAlphabet ( ) const
inlineoverridevirtualinherited

◆ getContent() [1/2]

◆ getContent() [2/2]

const std::vector<std::vector<double> >& bpp::ProbabilisticSymbolList::getContent ( ) const
inlineoverridevirtualinherited

◆ getCoordinate() [1/2]

virtual int bpp::CoreSiteInterface::getCoordinate ( ) const
pure virtualinherited

Get the coordinate associated to this site.

Returns
The coordinate of this site.

Implemented in bpp::AbstractCoreSite.

Referenced by bpp::SiteInterface::operator<(), bpp::AbstractCoreSite::operator=(), and bpp::SiteInterface::operator==().

◆ getCoordinate() [2/2]

int bpp::AbstractCoreSite::getCoordinate ( ) const
inlineoverridevirtualinherited

Get the coordinate associated to this site.

Returns
The coordinate of this site.

Implements bpp::CoreSiteInterface.

Definition at line 144 of file CoreSite.h.

References bpp::AbstractCoreSite::coordinate_.

Referenced by bpp::SiteContainerTools::resolveDottedAlignment().

◆ getElement() [1/2]

template<class T >
virtual const T& bpp::TemplateCoreSymbolListInterface< T >::getElement ( size_t  pos) const
pure virtualinherited

Get the element at position 'pos' as a character.

Parameters
posThe position of the character to retrieve.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

◆ getElement() [2/2]

const std::vector<double>& bpp::ProbabilisticSymbolList::getElement ( size_t  pos) const
inlineoverridevirtualinherited

Get the element at position 'pos' as a character.

Parameters
posThe position of the character to retrieve.

Implements bpp::TemplateCoreSymbolListInterface< T >.

Definition at line 167 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, and bpp::Table< class >::getColumn().

Referenced by bpp::ProbabilisticSymbolList::getValue().

◆ getStateValueAt()

double bpp::ProbabilisticSite::getStateValueAt ( size_t  sequencePosition,
int  state 
) const
inlinevirtual

get value of a state at a position

Parameters
sequencePositionindex of the looked value in the site
statestate in the alphabet
Returns
The state value at the given position.

Implements bpp::CoreSiteInterface.

Definition at line 139 of file ProbabilisticSite.h.

References bpp::ProbabilisticSymbolList::size().

◆ getTable() [1/2]

virtual const DTable& bpp::ProbabilisticSymbolListInterface::getTable ( ) const
pure virtualinherited

◆ getTable() [2/2]

const DTable& bpp::ProbabilisticSymbolList::getTable ( ) const
inlineoverridevirtualinherited

◆ getValue() [1/2]

◆ getValue() [2/2]

const std::vector<double>& bpp::ProbabilisticSymbolList::getValue ( size_t  pos) const
inlineoverridevirtualinherited

checked access to a character in list.

Parameters
posThe position to retrieve.
Returns
The T value of character at position pos.

Implements bpp::TemplateCoreSymbolListInterface< T >.

Definition at line 192 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::getElement().

◆ operator()() [1/2]

virtual double bpp::CruxSymbolListInterface::operator() ( size_t  position,
int  state 
) const
pure virtualinherited

get value of a state at a position

Short-cut for getStateValueAt.

Parameters
positionposition in the list
statestate in the alphabet
Returns
The state value at the given position.

Implemented in bpp::ProbabilisticSymbolList, and bpp::IntSymbolList.

◆ operator()() [2/2]

double bpp::ProbabilisticSymbolList::operator() ( size_t  position,
int  state 
) const
inlineoverridevirtualinherited

get value of a state at a position

Short-cut for getStateValueAt.

Parameters
positionposition in the list
statestate in the alphabet
Returns
The state value at the given position.

Implements bpp::CruxSymbolListInterface.

Definition at line 214 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, bpp::ProbabilisticSymbolList::getAlphabet(), and bpp::Table< class >::getColumn().

◆ operator=() [1/2]

ProbabilisticSite& bpp::ProbabilisticSite::operator= ( const ProbabilisticSite site)
inline

The assignment operator.

Definition at line 111 of file ProbabilisticSite.h.

References bpp::AbstractCoreSite::operator=(), and bpp::ProbabilisticSymbolList::operator=().

◆ operator=() [2/2]

ProbabilisticSite& bpp::ProbabilisticSite::operator= ( const ProbabilisticSiteInterface site)
inline

◆ operator[]() [1/4]

template<class T >
virtual const T& bpp::TemplateCoreSymbolListInterface< T >::operator[] ( size_t  pos) const
pure virtualinherited

Operator [] overloaded for quick access to a character in list.

Parameters
posThe position to retrieve.
Returns
The T value of character at position pos.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

◆ operator[]() [2/4]

const std::vector<double>& bpp::ProbabilisticSymbolList::operator[] ( size_t  pos) const
inlineoverridevirtualinherited

Operator [] overloaded for quick access to a character in list.

Parameters
posThe position to retrieve.
Returns
The T value of character at position pos.

Implements bpp::TemplateCoreSymbolListInterface< T >.

Definition at line 197 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, and bpp::Table< class >::getColumn().

◆ operator[]() [3/4]

std::vector<double>& bpp::ProbabilisticSymbolList::operator[] ( size_t  pos)
inlineoverridevirtualinherited

Operator [] overloaded for quick access to a character in list.

Parameters
posThe position to retrieve.
Returns
The T value of character at position pos.

Implements bpp::TemplateCoreSymbolListInterface< T >.

Definition at line 202 of file ProbabilisticSymbolList.h.

References bpp::ProbabilisticSymbolList::content_, and bpp::Table< class >::getColumn().

◆ operator[]() [4/4]

template<class T >
virtual T& bpp::TemplateCoreSymbolListInterface< T >::operator[] ( size_t  pos)
pure virtualinherited

Operator [] overloaded for quick access to a character in list.

Parameters
posThe position to retrieve.
Returns
The T value of character at position pos.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

◆ setContent() [1/5]

◆ setContent() [2/5]

virtual void bpp::ProbabilisticSymbolListInterface::setContent ( const DTable list)
pure virtualinherited

◆ setContent() [3/5]

void ProbabilisticSymbolList::setContent ( const std::vector< std::vector< double >> &  list)
overrideinherited

◆ setContent() [4/5]

template<class T >
virtual void bpp::TemplateCoreSymbolListInterface< T >::setContent ( const std::vector< T > &  list)
pure virtualinherited

Set the whole content of the list.

Parameters
listThe new content of the list.
See also
The list constructor for information about the way lists are internally stored.

Implemented in bpp::AbstractTemplateEventDrivenSymbolList< T >, and bpp::AbstractTemplateSymbolList< T >.

◆ setContent() [5/5]

virtual void bpp::TemplateCoreSymbolListInterface< T >::setContent
inherited

Set the whole content of the list.

Parameters
listThe new content of the list.
See also
The list constructor for information about the way lists are internally stored.

Referenced by bpp::ProbabilisticSymbolList::operator=(), and bpp::ProbabilisticSymbolList::ProbabilisticSymbolList().

◆ setCoordinate() [1/2]

void bpp::AbstractCoreSite::setCoordinate ( int  coordinate)
inlineoverridevirtualinherited

Set the position of this site.

Parameters
coordinateThe new position of the site.

Implements bpp::CoreSiteInterface.

Definition at line 146 of file CoreSite.h.

References bpp::AbstractCoreSite::coordinate_.

Referenced by bpp::CompressedVectorSiteContainer::reindexSites(), and bpp::CompressedVectorSiteContainer::setSiteCoordinates().

◆ setCoordinate() [2/2]

virtual void bpp::CoreSiteInterface::setCoordinate ( int  coordinate)
pure virtualinherited

Set the position of this site.

Parameters
coordinateThe new position of the site.

Implemented in bpp::AbstractCoreSite.

◆ setElement() [1/2]

void ProbabilisticSymbolList::setElement ( size_t  pos,
const std::vector< double > &  element 
)
overrideinherited

◆ setElement() [2/2]

template<class T >
virtual void bpp::TemplateCoreSymbolListInterface< T >::setElement ( size_t  pos,
const T &  c 
)
pure virtualinherited

Set the element at position 'pos' to character 'c'.

Parameters
posThe position of the character to set.
cThe value of the element.

Implemented in bpp::AbstractTemplateEventDrivenSymbolList< T >, and bpp::AbstractTemplateSymbolList< T >.

◆ shuffle() [1/2]

void bpp::ProbabilisticSymbolList::shuffle ( )
inlineoverridevirtualinherited

Randomly shuffle the content of the list, with linear complexity.

Implements bpp::CruxSymbolListInterface.

Definition at line 219 of file ProbabilisticSymbolList.h.

◆ shuffle() [2/2]

virtual void bpp::CruxSymbolListInterface::shuffle ( )
pure virtualinherited

Randomly shuffle the content of the list, with linear complexity.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

◆ size() [1/2]

virtual size_t bpp::CruxSymbolListInterface::size ( ) const
pure virtualinherited

Get the number of elements in the list.

Returns
The number of sites in the list.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, and bpp::ProbabilisticSymbolList.

Referenced by bpp::AbstractTemplateSymbolList< T >::AbstractTemplateSymbolList(), bpp::SequenceWithQuality::addElement(), 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::SequenceTools::findFirstOf(), bpp::SequenceTools::getCDS(), bpp::GeneticCode::getCodingSequence(), bpp::SymbolListTools::getCounts(), bpp::SymbolListTools::getCountsResolveUnknowns(), bpp::SymbolListTools::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::SequenceTools::getSequenceWithCompleteSites(), bpp::SequenceTools::getSequenceWithoutGaps(), bpp::SequenceTools::getSequenceWithoutStops(), bpp::SymbolListTools::hasGap(), bpp::SymbolListTools::hasSingleton(), bpp::SymbolListTools::hasUnknown(), bpp::SymbolListTools::hasUnresolved(), bpp::SymbolListTools::heterozygosity(), bpp::SequenceTools::invert(), bpp::SequenceTools::invertComplement(), bpp::SymbolListTools::isComplete(), bpp::SymbolListTools::isConstant(), bpp::SymbolListTools::isDoubleton(), bpp::SymbolListTools::isGapOnly(), bpp::SymbolListTools::isGapOrUnresolvedOnly(), bpp::SymbolListTools::isParsimonyInformativeSite(), bpp::SymbolListTools::isTriplet(), bpp::SequenceMask::isValidWith(), bpp::SequenceQuality::isValidWith(), bpp::SymbolListTools::jointEntropy(), bpp::SymbolListTools::mutualInformation(), bpp::SymbolListTools::numberOfGaps(), bpp::SymbolListTools::numberOfUnresolved(), bpp::AbstractTemplateSymbolList< T >::operator=(), bpp::SiteInterface::operator==(), bpp::SequenceWithQualityTools::removeGaps(), bpp::SequenceTools::removeGaps(), bpp::SequenceTools::removeStops(), bpp::SequenceTools::replaceStopsWithGaps(), bpp::CodonAlphabet::reverse(), bpp::WordAlphabet::reverse(), bpp::NucleicAcidsReplication::reverse(), bpp::AbstractReverseTransliterator::reverse(), bpp::SequenceTools::RNYslice(), bpp::SequenceWalker::SequenceWalker(), bpp::SequenceTools::subseq(), bpp::SequenceWithQualityTools::subseq(), bpp::SequenceTools::subtractHaplotype(), bpp::NucleicAcidsReplication::translate(), bpp::AbstractTransliterator::translate(), bpp::CodonAlphabet::translate(), bpp::WordAlphabet::translate(), bpp::SymbolListTools::variabilityFactorial(), and bpp::SymbolListTools::variabilityShannon().

◆ size() [2/2]

size_t bpp::ProbabilisticSymbolList::size ( ) const
inlineoverridevirtualinherited

◆ toString() [1/2]

virtual std::string bpp::CruxSymbolListInterface::toString ( ) const
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.

Returns
The whole list as a string.

Implemented in bpp::AbstractTemplateSymbolList< T >, bpp::AbstractTemplateSymbolList< int >, bpp::Sequence, bpp::ProbabilisticSymbolList, bpp::EventDrivenIntSymbolList, and bpp::IntSymbolList.

◆ toString() [2/2]

string ProbabilisticSymbolList::toString ( ) const
overridevirtualinherited

Convert the list as a string.

This method is useful for dumping a list to a file or to the screen for display.

Returns
The whole list as a string.

Implements bpp::CruxSymbolListInterface.

Definition at line 108 of file ProbabilisticSymbolList.cpp.

References bpp::ProbabilisticSymbolList::content_, bpp::Table< class >::getNumberOfColumns(), bpp::Table< class >::getNumberOfRows(), and bpp::Table< class >::getRowName().

Member Data Documentation

◆ alphabet_

std::shared_ptr<const Alphabet> bpp::ProbabilisticSymbolList::alphabet_
privateinherited

The Alphabet attribute must be initialized in the constructor and then can never be changed.

To apply another alphabet to the list requires creating another list.

Definition at line 71 of file ProbabilisticSymbolList.h.

Referenced by bpp::ProbabilisticSymbolList::alphabet(), bpp::ProbabilisticSymbolList::getAlphabet(), bpp::ProbabilisticSymbolList::operator=(), bpp::ProbabilisticSymbolList::ProbabilisticSymbolList(), and bpp::ProbabilisticSymbolList::setContent().

◆ content_

◆ coordinate_

int bpp::AbstractCoreSite::coordinate_
privateinherited

The position associated with this site.

Definition at line 85 of file CoreSite.h.

Referenced by bpp::AbstractCoreSite::getCoordinate(), bpp::AbstractCoreSite::operator=(), and bpp::AbstractCoreSite::setCoordinate().


The documentation for this class was generated from the following file: