forked from josiahseaman/skittle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
OligomerDisplay.h
100 lines (87 loc) · 2.49 KB
/
OligomerDisplay.h
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
#ifndef OLIG_DISP
#define OLIG_DISP
//#include <GL/glut.h>
#include <QtOpenGL/QGLWidget>
#include <math.h>
#include <stdlib.h>
#include <string>
#include <vector>
#include <QGLWidget>
#include "BasicTypes.h"
#include "RepeatMap.h"
#include "UiVariables.h"
#include "AbstractGraph.h"
class QSpinBox;
using namespace std;
class OligomerDisplay : public AbstractGraph//: public RepeatMap//
{
Q_OBJECT
public:
OligomerDisplay(UiVariables* gui, GLWidget* gl);
~OligomerDisplay();
QScrollArea* settingsUi();
void checkVariables();
void calculateOutputPixels();
void display();
//vector<color> calculateAverageSignature(int, int);
//void isochores();
void calculateHeatMap();
vector<double> fillHalfMatrix(vector<double>& data);
vector<double> rotateSquareMatrix(vector<double>& data);
void selfCorrelationMap();
void superCorrelationMap();
vector<double> copyVectorRange(vector<double>& stuff, int index, int length);
vector<color> colorNormalized(vector<double> heatData);
color redBlueSpectrum(double i);
void load_canvas();
GLuint render();
void freq_map();
int oligToNumber(string a);
string numberToOlig(int);
int height();
string SELECT_MouseClick(point2D pt);
void display_freq();
void calculate(vector<color>& img, int vote_size);
double correlate(vector<double>& apples, vector<double>& oranges);
void assignRanks(vector<point>& temp);
double spearmanCorrelation(vector<double>& apples, vector<double>& oranges);
int countsGraphWidth();
int heatMapGraphWidth();
int width();
public slots:
void changeMinDelta(double mD);
void changeWordLength(int);
void graphOneDisplay(int);
void graphTwoDisplay(int);
void graphThreeDisplay(int);
signals:
void wordLengthChanged(int);
private:
TextureCanvas* graphBuffer;
TextureCanvas* avgBuffer;
TextureCanvas* heatMapBuffer;
TextureCanvas* correlationBuffer;
TextureCanvas* superBuffer;
vector< vector<double> > freq;
vector<color> pixels;
vector<int> boundaryIndices;
vector<double> scores;
vector<double> correlationScores;
int wordLength;
int widthMultiplier;
int similarityGraphWidth;
double minDeltaBoundary;
QSpinBox* oligDial;
double min_score;
double max_score;
double range;
int F_width;
int F_height;
bool graphOneOn;
bool graphTwoOn;
bool graphThreeOn;
QCheckBox *graphOne;
QCheckBox *graphTwo;
QCheckBox *graphThree;
};
#endif