nct.networkblast
Class HomologyGraph

java.lang.Object
  extended by nct.graph.BasicGraph<NodeType,WeightType>
      extended by nct.graph.BasicKPartiteGraph<java.lang.String,java.lang.Double,SequenceGraph<java.lang.String,java.lang.Double>>
          extended by nct.networkblast.HomologyGraph
All Implemented Interfaces:
java.lang.Cloneable, java.lang.Comparable<Graph<java.lang.String,java.lang.Double>>, Graph<java.lang.String,java.lang.Double>, KPartiteGraph<java.lang.String,java.lang.Double,SequenceGraph<java.lang.String,java.lang.Double>>

public class HomologyGraph
extends BasicKPartiteGraph<java.lang.String,java.lang.Double,SequenceGraph<java.lang.String,java.lang.Double>>

This class creates a K-partite graph based on the homology of proteins between two or more species.


Field Summary
protected  double exThresh
           
protected  HomologyModel homModel
           
 
Fields inherited from class nct.graph.BasicKPartiteGraph
K, partitionMap, UNLIMITED_PARTITIONS
 
Fields inherited from class nct.graph.BasicGraph
assumeGraphFinished, descMap, id, numEdges, score, weightMap
 
Constructor Summary
HomologyGraph(HomologyModel homModel, double exThresh)
           
HomologyGraph(HomologyModel homModel, double exThresh, java.util.Collection<SequenceGraph<java.lang.String,java.lang.Double>> graphs)
           
 
Method Summary
 boolean addGraph(SequenceGraph<java.lang.String,java.lang.Double> sg)
          Adds the nodes of the specified graph to this graph and adds the graph as a partition.
 
Methods inherited from class nct.graph.BasicKPartiteGraph
addEdge, addNode, addNode, getAllKCliques, getK, getNumPartitions, getPartitions, isPartition
 
Methods inherited from class nct.graph.BasicGraph
addEdge, clone, compareTo, degreeOfNode, getEdge, getEdgeDescription, getEdgeList, getEdges, getEdgeWeight, getId, getNeighbors, getNodes, getScore, isEdge, isNode, numberOfEdges, numberOfNodes, removeEdge, removeNode, setEdgeDescription, setEdgeWeight, setScore, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface nct.graph.Graph
addEdge, clone, compareTo, degreeOfNode, getEdge, getEdgeDescription, getEdgeList, getEdges, getEdgeWeight, getId, getNeighbors, getNodes, getScore, isEdge, isNode, numberOfEdges, numberOfNodes, removeEdge, removeNode, setEdgeDescription, setEdgeWeight, setScore, toString
 

Field Detail

homModel

protected HomologyModel homModel

exThresh

protected double exThresh
Constructor Detail

HomologyGraph

public HomologyGraph(HomologyModel homModel,
                     double exThresh)
Parameters:
homModel - The homology model used to generate the edges in the graph.
exThresh - The expectation threshold. Expectation values above this threshold will not be added to the graph.

HomologyGraph

public HomologyGraph(HomologyModel homModel,
                     double exThresh,
                     java.util.Collection<SequenceGraph<java.lang.String,java.lang.Double>> graphs)
Parameters:
homModel - The homology model used to generate the edges in the graph.
exThresh - The expectation threshold. Expectation values above this threshold will not be added to the graph.
graphs - A collection of graphs to be added to this graph.
Method Detail

addGraph

public boolean addGraph(SequenceGraph<java.lang.String,java.lang.Double> sg)
Adds the nodes of the specified graph to this graph and adds the graph as a partition.

Parameters:
sg - The SequenceGraph to be added to this graph.
Returns:
Returns true if we're able to add the graph as a partition and we successfully add at least one node to the graph.