File: RootedTreeOutput.h

package info (click to toggle)
clustalx 2.1%2Blgpl-9
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 3,324 kB
  • sloc: cpp: 40,050; sh: 163; xml: 102; makefile: 16
file content (46 lines) | stat: -rw-r--r-- 1,148 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
 * Author: Mark Larkin
 * 
 * Copyright (c) 2007 Des Higgins, Julie Thompson and Toby Gibson.  
 */
/**
 * Changes:
 * mark 8-5-2007: I removed the isLeafNode function. Changed both the traversal functions
 * to access Node's data members via functions.
 */
#ifndef ROOTEDTREEOUTPUT_H
#define ROOTEDTREEOUTPUT_H

#include <fstream>
#include "RootedGuideTree.h"
#include "../../general/clustalw.h"


/** this is only used for upgma?!
 *
 */


namespace clustalw
{

class RootedTreeOutput
{
    public:
        RootedTreeOutput(SeqInfo* seqInfo);
        void printPhylipTree(RootedGuideTree* tree, ofstream* ptrToFile, Alignment *alignPtr,
                             DistMatrix* distMat);
        void printNexusTree(RootedGuideTree* tree, ofstream* ptrToFile, Alignment *alignPtr, 
                            DistMatrix* distMat);                   
                
    private:
        void phylipTraverse(ofstream* ptrToFile, Alignment *alignPtr, Node* tree);
        void nexusTraverse(ofstream* ptrToFile, Alignment *alignPtr, Node* tree);
        int firstSeq;
        int lastSeq;
        int numSeqs;                  
};

}

#endif