Package cytoscape

Examples of cytoscape.CyNode


  }
 
  public void addNodesToGRN() {
    CyAttributes nAtts = Cytoscape.getNodeAttributes();
    for (Object obj: sbmlNetwork.nodesList()){
      CyNode node = (CyNode) obj;
      String type = (String) nAtts.getAttribute(node.getIdentifier(), CySBMLConstants.ATT_SBOTERM);
      if (GeneRegulatoryNetwork.speciesSBOforGRN.contains(type)){
        nodeIds.add(node.getRootGraphIndex());
      }
    } 
  }
View Full Code Here


   
  }
 
  public void addEdgesToGRN() {
    for (Object obj: sbmlNetwork.nodesList()){
      CyNode node = (CyNode) obj;
      String type = (String) nAtts.getAttribute(node.getIdentifier(), CySBMLConstants.ATT_TYPE);
      if (type.equals(CySBMLConstants.NODETYPE_REACTION)){
        addEdgesToGRNForReaction(node);
      }
    }   
  }
View Full Code Here

    int[] outEdgeInds = sbmlNetwork.getAdjacentEdgeIndicesArray(reaction.getRootGraphIndex(), false, false, true);
   
    for (int in: inEdgeInds){
      CyEdge inEdge  = (CyEdge) sbmlNetwork.getEdge(in);
      String inEdgeSBO = (String) eAtts.getAttribute(inEdge.getIdentifier(), CySBMLConstants.ATT_SBOTERM);
      CyNode n1 = (CyNode) inEdge.getSource();
      if (inEdgeSBO == null){
        continue;
      }
      for (int out: outEdgeInds){
        // Get the two edges and end nodes;  n1 --inEdge-> reaction --outEdge-> n2
        CyEdge outEdge = (CyEdge) sbmlNetwork.getEdge(out);
        String outEdgeSBO = (String) eAtts.getAttribute(outEdge.getIdentifier(), CySBMLConstants.ATT_SBOTERM);
        System.out.println("OUT edge: " + outEdge.getIdentifier());
       
        CyNode n2 = (CyNode) outEdge.getTarget();       
        if (outEdgeSBO == null){
          continue;
        }
        // Edges to add
        if (GeneRegulatoryNetwork.productSBOforGRN.contains(outEdgeSBO) &&
View Full Code Here

TOP

Related Classes of cytoscape.CyNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.