-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpairwisedistancesplugin.h
117 lines (94 loc) · 3.22 KB
/
pairwisedistancesplugin.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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
/* Extension of Gama-q2 for excluding outlying coupples of distances
based on Normal distribution test.
Copyright (C) 2016 Dominik Hladík
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>
*/
#ifndef PAIRWISEDISTANCESPLUGIN_H
#define PAIRWISEDISTANCESPLUGIN_H
#include <QObject>
#include <QString>
#include <QMainWindow>
#include <QStatusBar>
#include <QMenu>
#include <QMenuBar>
#include <QHBoxLayout>
#include <QVBoxLayout>
#include <QGridLayout>
#include <QAction>
#include <QPushButton>
#include <QSpinBox>
#include <QTableWidget>
#include <QWidget>
#include <QCheckBox>
#include <QDialog>
#include <QDialogButtonBox>
#include "gamaq2interfaces.h"
#include "data.h"
#include "datalist.h"
#include "coupple.h"
#include "coupplelist.h"
#include "mytablewidgetitem.h"
#include "help.h"
#include "networkadjustmentpanel.h"
#include <gnu_gama/local/network.h>
namespace GNU_gama {
namespace local {
class LocalNetwork;
}
}
using LocalNetwork = GNU_gama::local::LocalNetwork;
class QFrame;
class PairwiseDistancesPlugin : public QObject, AdjustmentInterface
{
Q_OBJECT
Q_PLUGIN_METADATA(IID "org.gnu.gama.gama-q2.AdjustmentInterface/1.0")
Q_INTERFACES(AdjustmentInterface)
public:
PairwiseDistancesPlugin();
QString getName();
QWidget* create(NetworkAdjustmentPanel* adjp);
private:
QAction *actionClose, *actionReset, *actionSetActive, *actionSetPassive,
*actionSortByQualityAsc, *actionSortByQualityDesc,
*actionHorizontal, *actionSlope, *actionUnused,
*actionStdev, *actionType, *actionTest, *actionOrientation, *actionSettings,
*actionAbout, *actionHelp;
NetworkAdjustmentPanel* nap {nullptr};
QString confName;
LocalNetwork* lnet {nullptr};
QMainWindow* mainWindow;
enum Headers{Id,Sort,Type,PointA,PointB,
ValueI,SigmaI,OrientationI,UseI,
ValueII,SigmaII,OrientationII,UseII,
Diff,Testing,Quality};
QString title = "Pairwise Distance plugin";
QColor color1 = QColor(255,255,255);
QColor color2 = QColor(240,240,240);
int statusBarTime = 4000;
int precission = 4;
CouppleList *couppleList;
QTableWidget* tableWidget;
QMainWindow* getMainWindow();
QTableWidget* getTable();
void createMenuBar();
void setCheckBoxState(const QList<Coupple*> &data);
void calculate(const int &row,const QList<Coupple*> &data);
void setTableData();
void filter();
void filter(const int &row);
void about();
QDialog *getSettings();
void reset();
static double round(const double &value, const int &decimals);
private slots:
};
#endif // PAIRWISEDISTANCESPLUGIN_H