21 #ifndef _TLPGRAPHMEASEURE_H 22 #define _TLPGRAPHMEASEURE_H 26 #include <tulip/Node.h> 27 #include <tulip/MutableContainer.h> 28 #include <tulip/DoubleProperty.h> 29 #include <tulip/StaticProperty.h> 35 enum EDGE_TYPE {UNDIRECTED = 0, INV_DIRECTED = 1, DIRECTED = 2};
36 #define IN_EDGE INV_DIRECTED 37 #define OUT_EDGE DIRECTED 38 #define INOUT_EDGE UNDIRECTED 46 TLP_SCOPE
double averagePathLength(
const Graph* g, PluginProgress* = NULL);
53 TLP_SCOPE
double averageClusteringCoefficient(
const Graph *, PluginProgress * = NULL);
62 TLP_SCOPE _DEPRECATED
void clusteringCoefficient(
const Graph *g, MutableContainer<double> &result,
unsigned int maxDepth = 1, PluginProgress* = NULL);
70 TLP_SCOPE
void clusteringCoefficient(
const Graph *g, tlp::NodeStaticProperty<double> &result,
unsigned int maxDepth = 1, PluginProgress* = NULL);
77 TLP_SCOPE _DEPRECATED
void dagLevel(
const Graph *graph, MutableContainer<unsigned int> &level, PluginProgress* = NULL);
88 TLP_SCOPE
void degree(
const Graph *graph, tlp::NodeStaticProperty<double> °,
89 EDGE_TYPE direction = UNDIRECTED,
90 NumericProperty* weights = NULL,
bool norm =
false);
98 TLP_SCOPE
void dagLevel(
const Graph *graph, tlp::NodeStaticProperty<unsigned int> &level, PluginProgress* = NULL);
100 TLP_SCOPE
unsigned int maxDegree(
const Graph *);
102 TLP_SCOPE
unsigned int minDegree(
const Graph *);
110 TLP_SCOPE _DEPRECATED
unsigned int maxDistance(
const Graph *graph,
const node n, MutableContainer<unsigned int> &distance, EDGE_TYPE direction = UNDIRECTED);
118 TLP_SCOPE
unsigned int maxDistance(
const Graph *graph,
const unsigned int nPos, tlp::NodeStaticProperty<unsigned int> &distance, EDGE_TYPE direction = UNDIRECTED);
126 TLP_SCOPE _DEPRECATED
void reachableNodes(
const Graph *graph,
const node startNode, std::set<node> &result,
unsigned int maxDistance, EDGE_TYPE direction = UNDIRECTED);
135 TLP_SCOPE
void markReachableNodes(
const Graph *graph,
const node startNode, TLP_HASH_MAP<node, bool> &reachables,
unsigned int maxDistance, EDGE_TYPE direction = UNDIRECTED);