|
| TLocClust (const PUNGraph &GraphPt, const double &AlphaVal) |
|
int | Len () const |
| Returns the support of the approximate random walk, the number of nodes with non-zero PageRank score. More...
|
|
int | GetRndWalkSup () const |
| Returns the support of the approximate random walk, the number of nodes with non-zero PageRank score. More...
|
|
int | GetNId (const int &NodeN) const |
| Returns the ID of the NodeN-th node in the sweep vector. More...
|
|
int | GetVol (const int &Nodes) const |
| Returns the volume of the set of first NodeN nodes in the sweep vector. More...
|
|
int | GetCut (const int &Nodes) const |
| Returns the size of the cut of the first Nodes nodes in the sweep vector. More...
|
|
double | GetPhi (const int &ValId) const |
| Returns the conductance of the cut separating the first Nodes nodes in the sweep vector from the rest of the graph. More...
|
|
const TIntV & | GetNIdV () const |
| Vector of node IDs sorted in the random walk order. More...
|
|
const TIntV & | GetVolV () const |
| Volume (sum of the degrees) of first K-nodes in the node-id vector (GetNIdV()). More...
|
|
const TIntV & | GetCutV () const |
| Edges cut to separate the first K-nodes in the node-id vector (GetNIdV()) from the rest of the graph. More...
|
|
const TFltV & | GetPhiV () const |
| Conducatance of the cut separating first K-nodes in the node-id vector (GetNIdV()) from the rest of the graph. More...
|
|
int | BestCut () const |
| Index K of the cut of the minimum conductance around the seed node. More...
|
|
int | BestCutNodes () const |
| Number of nodes inside the 'best' (minimum conductance) cut. More...
|
|
int | GetCutEdges () const |
| Number of edges in the 'best' (minimum conductance) cut. More...
|
|
int | GetCutVol () const |
| Volume of the 'best' (minimum conductance) cut. More...
|
|
double | GetCutPhi () const |
| Conductance of the 'best' (minimum conductance) cut. More...
|
|
int | ApproxPageRank (const int &SeedNode, const double &Eps) |
| Computes Approximate PageRank from the seed node SeedNId and with tolerance Eps. More...
|
|
void | SupportSweep () |
| After the function ApproxPageRank() has been run the SupportSweep() computes the volume, cut size, node ids, conductance vectors. More...
|
|
void | FindBestCut (const int &SeedNode, const int &ClustSz, const double &MinSizeFrac=0.2) |
| Finds minimum conductance cut in the graph around the seed node. More...
|
|
void | PlotVolDistr (const TStr &OutFNm, TStr Desc=TStr()) const |
| Plots the cluster volume vs. cluster size K (cluster is composed of nodes NIdV[1...K]). More...
|
|
void | PlotCutDistr (const TStr &OutFNm, TStr Desc=TStr()) const |
| Plots the cluster cut size vs. cluster size K (cluster is composed of nodes NIdV[1...K]). More...
|
|
void | PlotPhiDistr (const TStr &OutFNm, TStr Desc=TStr()) const |
| Plots the cluster conductance vs. cluster size K (cluster is composed of nodes NIdV[1...K]). More...
|
|
void | SavePajek (const TStr &OutFNm) const |
| Saves the network in the Pajek format so it can be visualized. Red node represents the seed and color the cluster membership. More...
|
|
|
static void | DrawWhiskers (const PUNGraph &Graph, TStr FNmPref, const int &PlotN) |
| Draws the 'whiskers' of the graph. Whiskers are small sub-graphs that are attached to the rest of the graph via a single edge. More...
|
|
static void | GetCutStat (const PUNGraph &Graph, const TIntV &NIdV, int &Vol, int &Cut, double &Phi, int GraphEdges=-1) |
| For a given Graph and a set of nodes NIdV the function returns the Volume, CutSize and the Conductance of the cut. More...
|
|
static void | GetCutStat (const PUNGraph &Graph, const TIntSet &NIdSet, int &Vol, int &Cut, double &Phi, int GraphEdges=-1) |
| For a given Graph and a set of nodes NIdV the function returns the Volume, CutSize and the Conductance of the cut. More...
|
|
static void | PlotNCP (const PUNGraph &Graph, const TStr &FNm, const TStr Desc="", const bool &BagOfWhiskers=true, const bool &RewireNet=false, const int &KMin=10, const int &KMax=Mega(100), const int &Coverage=10, const bool &SaveTxtStat=false, const bool &PlotBoltzman=false) |
|
Local Spectral Clustering algorithm.
The code implements the PageRank Nibble local clustering algorithm of Andersen, Chung and Lang. Given a single starting seed node, the algorithm will then find the clusters around that node. This is achieved by the algorithm finding the approximate personalized PageRank score of every node with respect to the Seed node. Nodes are then ordered by the PageRank score and the idea is then that by 'sweeping' the vector of PageRank scores one can find communities around the chosen seed node. The idea is to try out K = 1...N/2 and then for a set of {node_1 ... node_K} test the value of the conductance (Phi). If the conductance at certain value of K achieves a local minima, then we found a good cut in the graph. This method is also used for computing the Network Community Profile plots. See: Local Graph Partitioning using PageRank Vectors by R. Andersen, F. Chung and K. Lang URL: http://www.math.ucsd.edu/~fan/wp/localpartition.pdf
Definition at line 24 of file ncp.h.