-
Notifications
You must be signed in to change notification settings - Fork 5
/
gda_weights.h
68 lines (56 loc) · 2.61 KB
/
gda_weights.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
#ifndef __JSGEODSA_GDA_WEIGHTS__
#define __JSGEODSA_GDA_WEIGHTS__
#include <string>
class AbstractGeoDa;
class GeoDaWeight;
// APIs of weights creation
/**
*
* @param geoda
* @param polyid
* @param order
* @param include_lower_order
* @param precision_threshold
* @return
*/
GeoDaWeight* gda_queen_weights(AbstractGeoDa* geoda,
unsigned int order,
bool include_lower_order,
double precision_threshold);
GeoDaWeight* gda_rook_weights(AbstractGeoDa* geoda,
unsigned int order,
bool include_lower_order,
double precision_threshold);
GeoDaWeight* gda_knn_weights(AbstractGeoDa* geoda, unsigned int k,
double power,
bool is_inverse,
bool is_arc,
bool is_mile,
const std::string& kernel,
double bandwidth,
bool adaptive_bandwidth,
bool use_kernel_diagonals,
const std::string& polyid);
GeoDaWeight* gda_knn_weights_sub(AbstractGeoDa* geoda, unsigned int k, int start, int end,
double power,
bool is_inverse,
bool is_arc,
bool is_mile,
const std::string& kernel,
double bandwidth,
bool adaptive_bandwidth,
bool use_kernel_diagonals,
const std::string& polyid);
double gda_min_distthreshold(AbstractGeoDa* geoda, bool is_arc, bool is_mile);
GeoDaWeight* gda_distance_weights(AbstractGeoDa* geoda, double dist_thres,
const std::string& polyid,
double power,
bool is_inverse,
bool is_arc,
bool is_mile,
const std::string& kernel,
bool use_kernel_diagonals);
GeoDaWeight* gda_load_gal(const char* weights_path, const std::vector<std::string>& id_vec = std::vector<std::string>());
GeoDaWeight* gda_load_gwt(const char* weights_path, const std::vector<std::string>& id_vec = std::vector<std::string>());
GeoDaWeight* gda_load_swm(const char* weights_path, const std::vector<int>& id_vec = std::vector<int>());
#endif