52 const std::vector<std::shared_ptr<ProbabilisticSequence>>& vs,
57 for (
auto i = vs.begin(); i < vs.end(); i++)
69 for (
size_t i = 0; i < max; i++)
89 const std::vector<std::string>& names,
96 for (
size_t i = 0; i < names.size(); i++)
99 for (
size_t j = 0; j < i; j++)
101 if (names[j] == names[i])
102 throw Exception(
"VectorSiteContainer::setSequenceNames : Sequence's name already exists in container");
106 for (
size_t i = 0; i < names.size(); i++)
Partial implementation of the OrderedSequenceContainer interface.
void setGeneralComments(const Comments &comments)
Set the comments of this container.
const Alphabet * getAlphabet() const
Get container's alphabet.
AbstractValuesContainer & operator=(const AbstractValuesContainer &sc)
const Comments & getGeneralComments() const
Get the comments of this container.
virtual void setName(const std::string &name)=0
Set the name of this sequence.
The probabilistic sequence interface.
The template VectorMappedContainer class.
VectorMappedContainer< T > & operator=(const VectorMappedContainer &vsc)
void setObjectNames(const std::vector< std::string > &names)
The VectorProbabilisticSequenceContainer class.
VectorProbabilisticSequenceContainer * createEmptyContainer() const
Return a copy of this container, but with no data inside.
void clear()
Delete all objects in the container.
ProbabilisticSequence & getSequence_(size_t i)
size_t getNumberOfSequences() const
Get the number of sequences in the container.
VectorProbabilisticSequenceContainer(const std::vector< std::shared_ptr< ProbabilisticSequence >> &vs, const Alphabet *alpha)
Build a container with shared Sequences.
virtual void addSequence(const ProbabilisticSequence &sequence, bool checkName=true)
Add a sequence at the end of the container.
const ProbabilisticSequence & getSequence(const std::string &name) const
void setSequenceNames(const std::vector< std::string > &names, bool checkNames=true)
Set all sequence names.
VectorProbabilisticSequenceContainer & operator=(const VectorProbabilisticSequenceContainer &vsc)
Assign from a VectorProbabilisticSequenceContainer.
This alphabet is used to deal NumericAlphabet.