org.gersteinlab.tyna.core.operators
Class StatisticsFilter

java.lang.Object
  extended by org.gersteinlab.tyna.core.operators.StatisticsFilter
All Implemented Interfaces:
UnaryOperator

public class StatisticsFilter
extends java.lang.Object
implements UnaryOperator

        This class defines the statistical filter, which is a unary graph
        operator. It takes a graph as input, and returns a graph that
        satisfies some statistical requirements.
        

Version:
1.0 (November 6, 2005) Change History: 1.0 - Initial version
Author:
Kevin Yuk-Lap Yip

Field Summary
static java.lang.String BETWEENNESSES
           
static java.lang.String CLUS_COEFS
           
static java.lang.String DEGREES
           
static java.lang.String ECCENTRICITIES
           
static java.lang.String EQ
           
protected  java.lang.String filterName
          The name of the filtering statistic
protected  java.lang.String filterOp
          The filtering operator
protected  java.lang.String filterUnit
          The filtering unit
protected  double filterValue
          The filtering value
static java.lang.String GEQ
           
static java.lang.String GT
           
static java.lang.String IN_DEGREES
           
protected  boolean includeNeighbors
          Whether to include the neighbors of the nodes that pass the requirements
static java.lang.String LEQ
           
static java.lang.String LT
           
static java.lang.String OUT_DEGREES
           
static java.lang.String PERCENTILE
           
static java.lang.String SD
           
static java.lang.String VALUE
           
 
Constructor Summary
StatisticsFilter(java.lang.String filterName, java.lang.String filterOp, double filterValue, java.lang.String filterUnit, boolean includeNeighbors)
          Create a new statistics filter.
 
Method Summary
 Graph operate(Graph graph)
          Perform the operation on a graph.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEGREES

public static final java.lang.String DEGREES
See Also:
Constant Field Values

IN_DEGREES

public static final java.lang.String IN_DEGREES
See Also:
Constant Field Values

OUT_DEGREES

public static final java.lang.String OUT_DEGREES
See Also:
Constant Field Values

CLUS_COEFS

public static final java.lang.String CLUS_COEFS
See Also:
Constant Field Values

ECCENTRICITIES

public static final java.lang.String ECCENTRICITIES
See Also:
Constant Field Values

BETWEENNESSES

public static final java.lang.String BETWEENNESSES
See Also:
Constant Field Values

LT

public static final java.lang.String LT
See Also:
Constant Field Values

LEQ

public static final java.lang.String LEQ
See Also:
Constant Field Values

EQ

public static final java.lang.String EQ
See Also:
Constant Field Values

GEQ

public static final java.lang.String GEQ
See Also:
Constant Field Values

GT

public static final java.lang.String GT
See Also:
Constant Field Values

VALUE

public static final java.lang.String VALUE
See Also:
Constant Field Values

SD

public static final java.lang.String SD
See Also:
Constant Field Values

PERCENTILE

public static final java.lang.String PERCENTILE
See Also:
Constant Field Values

filterName

protected java.lang.String filterName
The name of the filtering statistic


filterOp

protected java.lang.String filterOp
The filtering operator


filterValue

protected double filterValue
The filtering value


filterUnit

protected java.lang.String filterUnit
The filtering unit


includeNeighbors

protected boolean includeNeighbors
Whether to include the neighbors of the nodes that pass the requirements

Constructor Detail

StatisticsFilter

public StatisticsFilter(java.lang.String filterName,
                        java.lang.String filterOp,
                        double filterValue,
                        java.lang.String filterUnit,
                        boolean includeNeighbors)
Create a new statistics filter.

Parameters:
filterName - The name of the filtering statistic
filterOp - The filtering operator
filterValue - The filtering value
filterUnit - The filtering unit
includeNeighbors - Whether to include the neighbors of the nodes that pass the requirements
Method Detail

operate

public Graph operate(Graph graph)
              throws GraphTypeException
Description copied from interface: UnaryOperator
Perform the operation on a graph.

Specified by:
operate in interface UnaryOperator
Parameters:
graph - The graph
Returns:
The resulting graph
Throws:
GraphTypeException - If there are problems with the type of the input graph