57 MafBlock* block = iterator_->nextBlock();
60 string start =
"StartNA";
61 string stop =
"StopNA";
73 std::ofstream output(file.c_str(), ios::out);
74 writeBlock(output, *block);
90 string positions =
"";
96 unsigned int count = 0;
98 for (
size_t j = 0; j < s.
size() &&
count < 2; ++j) {
118 variableSites->addSite(aln.
getSite(i));
123 out <<
"Distinct = " << nbDistinct << endl;
124 out <<
"Genes = " << nbGenes << endl;
125 out <<
"Loci = " << nbLoci << endl;
126 out <<
"K = -4 %4-allele model with Haplotype Alleles specified by A,C,G,T" << endl;
128 out <<
"Positions of loci:" << endl;
129 out << positions << endl;
131 out <<
"Haplotypes" << endl;
134 out << variableSites->getSequence(i).toString() <<
" 1" << endl;
virtual size_t getNumberOfSites() const=0
virtual size_t size() const=0
A synteny block data structure, the basic unit of a MAF alignement file.
AlignedSequenceContainer & getAlignment()
bool hasSequenceForSpecies(const std::string &species) const
const MafSequence & getSequenceForSpecies(const std::string &species) const
A sequence class which is used to store data from MAF files.
const std::string & getChromosome() const
virtual size_t getNumberOfSequences() const=0
virtual std::vector< std::string > getSequencesNames() const=0
MafBlock * analyseCurrentBlock_()
void writeBlock(std::ostream &out, const MafBlock &block) const
virtual const Site & getSite(size_t siteIndex) const=0
void replaceAll(std::string &target, const std::string &query, const std::string &replacement)
std::string toString(T t)
std::size_t count(const std::string &s, const std::string &pattern)