*
*/
-using namespace std;
-
-#include "ordervector.hpp"
-#include "sabundvector.hpp"
-#include "sharedsabundvector.h"
-#include "sharedordervector.h"
+#include "rabundvector.hpp"
+#include "sharedrabundvector.h"
#include "datavector.hpp"
#include "globaldata.hpp"
+/***********************************************************************/
+struct binCount {
+ int bin;
+ int abund;
+ binCount(int i, int j) : bin(i), abund(j) {}
+};
+/***********************************************************************/
+//sorts highest abund to lowest
+inline bool comparebinCounts(binCount left, binCount right){
+ return (left.abund > right.abund);
+}
/***********************************************************************/
class HeatMap {
public:
- HeatMap();
+ HeatMap(string, string, int, int, string);
~HeatMap(){};
- void getPic(OrderVector*);
- void getPic(SharedOrderVector*);
+ string getPic(RAbundVector*);
+ string getPic(vector<SharedRAbundVector*>);
private:
- void getSharedVectors(SharedOrderVector*);
- void setGroups();
-
- GlobalData* globaldata;
- vector<SharedSAbundVector> lookup;
- SAbundVector sabund;
- string format;
+ int sortSharedVectors(vector<SharedRAbundVector*>& );
+ void printLegend(int, float);
+ GlobalData* globaldata;
+ string format, sorted, groupComb, scaler, outputDir;
+ ofstream outsvg;
+ MothurOut* m;
+ int numOTU, fontSize;
+
+ map<int, int> orderTopGroup(vector<SharedRAbundVector*>&);
+ map<int, int> orderTopOtu(vector<SharedRAbundVector*>&);
+ map<int, int> orderShared(vector<SharedRAbundVector*>&);
};
+/***********************************************************************/
+
#endif
+
+
+