What Is an Interaction Network and How Do You Analyze One in Cytoscape?

Updated

An interaction network is a graph where nodes represent biological entities (genes, proteins, or other molecules) and edges represent relationships between them—such as physical binding, regulatory control, or co-expression. Cytoscape is an open-source platform for building, visualizing, and analyzing these networks. You can use it if you have interaction data in a supported format (SIF, edge tables, or similar) and want to move from a raw list of pairs to a visual, queryable graph. The sections below cover the core concepts, the import-and-layout workflow, the analysis features, and the problems that most often trip people up.

Nodes, edges, and what the connections actually mean

The vocabulary is small but worth fixing before you touch any software:

  • Node (vertex): one entity. In a protein–protein interaction network, each node is a protein; in a gene regulatory network, each node is a gene.
  • Edge (link): one relationship between two nodes. Edges can be directed (A regulates B) or undirected (A binds B), and can carry attributes like confidence score, evidence type, or direction of effect.
  • Degree: the number of edges touching a node. High-degree nodes are the hubs you'll look for later.

The critical point is that an edge means whatever your data source says it means. A "protein interaction" edge from an affinity-purification experiment and a "co-expression" edge from transcriptomics are not the same claim, even though both render as a line. Keep the evidence type as an edge attribute so you can filter on it later—otherwise you'll silently merge different kinds of evidence into one graph.

Getting interaction data in

Cytoscape does not generate interaction data; it consumes it. You need a file or a database query first.

Common formats:

Format Shape When it's the right choice
SIF (Simple Interaction Format) nodeA <interaction> nodeB, one row per edge Quick import of a plain edge list; interaction type becomes the edge name
Edge table (CSV/TSV) Columns for source, target, and optional attributes You have scores, directions, or evidence types to preserve
Node table (CSV/TSV) One row per node with attributes You want to attach expression values, annotations, or groups

Common sources: public interaction databases (for example STRING, BioGRID, or IntAct), your own experimental results, or a co-expression analysis. Most of these let you export a tab-delimited edge list, which is the easiest thing to bring into Cytoscape.

A practical rule: if your file has one row per pair, it's an edge table. If it has one row per entity, it's a node table. You'll often import both—edges to define the graph, nodes to color and size it.

Importing and laying out the network

The workflow is: import edges → import node attributes → choose a layout → adjust.

  1. Import the edge file. In Cytoscape, use the import option for network files and point it at your SIF or edge table. Specify which columns are source and target. Expected result: a network appears, possibly as an unreadable hairball.
  2. Import node attributes. Import your node table and map its key column to the existing node identifiers. Expected result: nodes now carry attributes (expression, annotation, group) that you can map to visual properties.
  3. Apply a layout. The default grid-like layout is rarely useful for biology. Force-directed layouts (for example Prefuse Force Directed or a spring-embedded layout) pull connected nodes together and push unconnected ones apart, which is what makes hubs and clusters visible.
  4. Map attributes to style. Use the Style panel to set node fill color, size, and edge width from your data columns. Sizing nodes by degree and coloring by expression or cluster is the standard first pass.

Verification: after import, check the node and edge counts against your source file. If Cytoscape reports fewer nodes than you expect, you likely have identifier mismatches (see troubleshooting below).

Finding hubs, clusters, and enriched pathways

Once the graph is loaded, Cytoscape's analysis features answer three different questions:

  • Which nodes are most connected? Use the network analysis to compute degree and other centrality measures, then sort or size by them. High-degree nodes are candidate hubs—but treat them as hypotheses, not conclusions, since a hub can also be an artifact of how often a protein was studied.
  • Which nodes group together? Use a clustering algorithm (for example MCODE for dense regions, or community-detection algorithms) to find modules. These often correspond to complexes or functional groups.
  • What do those groups mean biologically? Use enrichment analysis (for example via the ClueGO or Enrichr apps) to test whether a cluster's genes are over-represented in a pathway or GO term. This is where a graph turns into a biological statement.

The order matters: cluster first, then enrich the clusters. Enriching the whole network usually returns generic terms; enriching a tight module returns something specific.

Troubleshooting the usual failures

Missing edges or a smaller network than expected. Almost always an identifier problem. TP53, P04637, and ENSG00000141510 are the same gene but will be treated as three separate nodes. Normalize identifiers to one namespace before import, and check whether your source and target columns use the same namespace.

Disconnected components. If your network splits into many isolated islands, either your data genuinely has separate sub-networks or you filtered too aggressively. Don't delete small components reflexively—a two-node component can be a real interaction. Instead, decide explicitly whether you're analyzing the largest connected component and state that choice.

Layout clutter. A dense network rendered with all labels on is unreadable. Turn labels off by default, show them only for selected nodes or high-degree nodes, and use layout plus manual node dragging for the final figure. For publication figures, export at high resolution after the layout is stable.

Edges that look identical but aren't. If you imported multiple evidence types into one network, use edge color or line style to distinguish them, or split into separate networks. Merging without visual distinction hides the fact that a "strong" edge and a "weak" edge are being treated the same.

What to decide before you start

If your goal is a quick look at a known pathway, import a curated edge list, apply a force-directed layout, and stop there. If your goal is to find novel hubs or modules, budget time for identifier normalization and enrichment—the graph itself is the easy part, and the interpretation is where the work is. Cytoscape is free and open source; the platform's own site is the authoritative source for current download and app details.