数据挖掘
mmk27
这个作者很懒,什么都没留下…
展开
-
数据挖掘-diana算法
#include<bits/stdc++.h>using namespace std;#define INF 0x3f3f3f3fstruct node { double x, y; int id; node(double x_ = 0, double y_ = 0, int id_ = 0) { x = x_; y = y_; id = id_; }};...原创 2019-12-02 11:43:36 · 1940 阅读 · 3 评论 -
数据挖掘-agnes算法
#include <bits/stdc++.h>using namespace std;#define INF 0x3f3f3f3fvector<double> v[10010];int n, k;double average[10010]; int main() { cin >> n >> k; for(int i = 1; i ...原创 2019-12-02 11:08:50 · 810 阅读 · 0 评论 -
数据挖掘-knn
#include <bits/stdc++.h>using namespace std;const int N = 1e5 + 10;struct node { int id; double x, y;}a[N], b[N], t;int len, k;int n;double distance(node x, node y) { return sqrt((x.x...原创 2019-12-02 10:35:02 · 136 阅读 · 0 评论 -
数据挖掘-k平均算法
/*题目内容:实现k平均算法的代码,并且通过样例代码:*/#include <bits/stdc++.h>using namespace std;#define eps 1e-8#define INF 0x3f3f3f3fconst int N = 1e6 + 10;int n, k;pair<double, double> a[N], b[N];v...原创 2019-12-02 10:23:51 · 476 阅读 · 0 评论