]> git.donarmstrong.com Git - mothur.git/blob - sharedrabundvector.h
Initial revision
[mothur.git] / sharedrabundvector.h
1 #ifndef SHAREDVECTOR_H
2 #define SHAREDVECTOR_H
3
4 /*
5  *  sharedvector.h
6  *  Dotur
7  *
8  *  Created by Sarah Westcott on 12/5/08.
9  *  Copyright 2008 Schloss Lab UMASS Amherst. All rights reserved.
10  *
11  */
12
13 #include <Carbon/Carbon.h>
14 #include "datavector.hpp"
15 #include "sharedordervector.h"
16
17
18
19
20 class SharedRAbundVector : public DataVector {
21         
22 public:
23         SharedRAbundVector();
24         SharedRAbundVector(int);
25         //SharedRAbundVector(string, vector<int>);
26         SharedRAbundVector(const SharedRAbundVector& bv) : DataVector(bv), data(bv.data), maxRank(bv.maxRank), numBins(bv.numBins), numSeqs(bv.numSeqs){};
27 //      SharedRAbundVector(ifstream&);
28         ~SharedRAbundVector();
29
30         int getNumBins();               
31         int getNumSeqs();                                                       
32         int getMaxRank();
33         string getGroup();
34         void setGroup(string);                                                  
35
36         void set(int, int, string);     
37         individual get(int);
38         int getAbundance(int);
39         void push_back(int, int, string);
40         void pop_back();
41         void resize(int);
42         int size();
43         vector<individual>::reverse_iterator rbegin();
44         vector<individual>::reverse_iterator rend();
45         
46         void print(ostream&);
47                 
48         SharedRAbundVector getSharedRAbundVector();
49         SAbundVector getSAbundVector();
50         OrderVector getOrderVector(map<string,int>*);
51         SharedOrderVector getSharedOrderVector();
52         
53 private:
54         vector<individual>  data; 
55         int maxRank;
56         int numBins;
57         int numSeqs;
58         string group;   
59 };
60
61
62 #endif
63