|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbcds.phison.gm.GraphMetricBase<V,E>
bcds.phison.gm.Assortativity<V,E>
public class Assortativity<V,E>
Computes the assortativity coefficient of a graph, based on the Pearson correlation coefficient.
Constructor Summary | |
---|---|
Assortativity()
Default constructor. |
|
Assortativity(SimGraph<V,E> g,
Environ env)
Creates a new instance. |
Method Summary | |
---|---|
java.lang.String |
getDescription()
Returns a string describing the metric, for example, article where it has been published, URL where to find reference implementation, etc. |
double |
getGraphMetric()
Returns the graph's assortativity coefficient. |
java.lang.String |
getLabel()
Returns "Assortativity". |
boolean |
isApplicableTo(MetricTarget m)
Returns true if m is MetricTarget.GRAPH . |
void |
run()
Default implementation. |
void |
setup(SimGraph<V,E> g,
Environ env)
Saves the parameters for future use. |
Methods inherited from class bcds.phison.gm.GraphMetricBase |
---|
dump, getEdgeMetric, getEnviron, getEnvParams, getGraph, getGraphMetricStdev, getName, getNodeMetric |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface bcds.phison.gm.GraphMetric |
---|
dump, getEdgeMetric, getGraphMetricStdev, getNodeMetric |
Methods inherited from interface bcds.phison.WithEnvParams |
---|
getEnviron, getEnvParams, getName |
Constructor Detail |
---|
public Assortativity()
setup(SimGraph, Environ)
must be called.
public Assortativity(SimGraph<V,E> g, Environ env)
setup(bcds.phison.SimGraph, bcds.tools.Environ)
to complete the
inialization.
Method Detail |
---|
public void setup(SimGraph<V,E> g, Environ env)
GraphMetricBase
g
must
not be null. If env
is null, a new empty environment
is created. Default values are incorporated by calling
getEnvParams and the types of already-present
values are adapted, if possible.
setup
in interface GraphMetric<V,E>
setup
in class GraphMetricBase<V,E>
public boolean isApplicableTo(MetricTarget m)
m
is MetricTarget.GRAPH
.
isApplicableTo
in interface GraphMetric<V,E>
isApplicableTo
in class GraphMetricBase<V,E>
public double getGraphMetric()
getGraphMetric
in interface GraphMetric<V,E>
getGraphMetric
in class GraphMetricBase<V,E>
public void run()
GraphMetricBase
run
in interface GraphMetric<V,E>
run
in class GraphMetricBase<V,E>
public java.lang.String getLabel()
getLabel
in interface GraphMetric<V,E>
public java.lang.String getDescription()
GraphMetric
getDescription
in interface GraphMetric<V,E>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |