Tutorials › Multi-Omics Data Integration › Layered Node and Edge Representations

Graphical Models for Multi-Omics · Tutorial 293 of 597

Layered Node and Edge Representations

You will learn to index layer-labeled omics nodes and translate network structure into correctly dimensioned block adjacency and precision matrices.

Advanced 10 min read

What You'll Learn

  • Define nodes by both their omics layer and feature identity.
  • Choose a consistent global ordering for variables across layers.
  • Construct block adjacency matrices for within-layer and cross-layer edges.
  • Check matrix dimensions, symmetry, and edge counts for undirected networks.
  • Distinguish an adjacency matrix from a precision matrix and its edge support.
  • Identify common representation and interpretation errors.

From Omics Features to a Layered Network

A multi-omics network represents measured features as nodes and selected relationships as edges. A layered representation adds a label to each node indicating its data modality: for example, a gene-expression feature belongs to an RNA layer, a protein abundance feature to a protein layer, and a metabolite measurement to a metabolite layer. The layer label is part of the node’s identity, not merely a plotting color. Two features with similar names in different assays are distinct nodes unless the analysis explicitly defines them as the same variable.

The earlier material on graphical models as multi-omics dependency maps introduced networks as representations of dependencies among variables. Here the emphasis is on organizing such a network precisely: how to name nodes, divide a matrix into layer-specific blocks, and distinguish an adjacency representation from a precision-matrix representation. A network encoding does not by itself explain how edges were estimated, establish causality, or specify a biological mechanism.

Definition: Suppose there are \(L\) omics layers. Layer \(\ell\) contains \(p_\ell\) variables, indexed by \(a=1,\ldots,p_\ell\). A node is \(v_{\ell a}\): its first index identifies its layer and its second identifies a feature within that layer. The total number of nodes is \(P=\sum_{\ell=1}^{L}p_\ell\). A within-layer edge joins two nodes in the same layer; a cross-layer edge joins nodes in different layers.

For a joint network across modalities, the rows of the data are ordinarily aligned observations—often the same biological samples—with measurements available for the features being modeled. The graph’s nodes are variables, not samples. Missingness, repeated measurements, or unmatched sample sets require explicit handling before constructing a joint representation; a block matrix does not solve those data-design problems.

Block Adjacency Matrices

Choose and record an ordering of the nodes, such as all RNA variables first, then proteins, then metabolites. In an undirected network, let \(A_{\ell m}\) be the block whose rows index variables in layer \(\ell\) and whose columns index variables in layer \(m\). Its dimension is \(p_\ell\) by \(p_m\). The block \(A_{\ell\ell}\) records relationships within layer \(\ell\); \(A_{\ell m}\), for \(\ell\ne m\), records relationships from layer \(\ell\) to layer \(m\).

For a binary adjacency matrix, an entry is 1 when the corresponding edge is included and 0 otherwise. A weighted adjacency matrix instead records a specified edge weight, such as a signed association measure. The meaning and scale of a weight must be stated; a generic number in a matrix is not automatically a probability or a causal effect. With a consistent undirected encoding, \(A_{m\ell}=A_{\ell m}^{\mathsf T}\), so the full matrix is symmetric. If self-edges are excluded, the diagonal entries of each within-layer block are zero.

Worked Example: Building a Three-Layer Adjacency Matrix

Consider a hypothetical network with two RNA features \(R_1,R_2\), two protein features \(P_1,P_2\), and one metabolite feature \(M_1\). Use the global order \(R_1,R_2,P_1,P_2,M_1\). Suppose its undirected edges are \(R_1\)--\(R_2\), \(R_1\)--\(P_1\), and \(P_2\)--\(M_1\), with no other edges.

The within-RNA block is \(A_{\mathrm{RNA},\mathrm{RNA}}=\begin{pmatrix}0&1\\1&0\end{pmatrix}\). The RNA-to-protein block is \(A_{\mathrm{RNA},\mathrm{protein}}=\begin{pmatrix}1&0\\0&0\end{pmatrix}\), with its transpose in the protein-to-RNA position. The protein-to-metabolite block is \(\begin{pmatrix}0\\1\end{pmatrix}\), and its transpose occupies the metabolite-to-protein position. All other cross-layer blocks are zero.

Putting these blocks in the stated order gives

$$ A= \begin{pmatrix} 0&1&1&0&0\\ 1&0&0&0&0\\ 1&0&0&0&0\\ 0&0&0&0&1\\ 0&0&0&1&0 \end{pmatrix}. $$

For example, the entry in row 1, column 3 is 1 because \(R_1\)--\(P_1\) is present, and the equal entry in row 3, column 1 enforces undirected symmetry. The matrix is \(5\) by \(5\), matching the five total nodes. Its diagonal is zero because no self-edges were specified.

The block structure gives a direct accounting of which kinds of relationships are represented. For an undirected network, every cross-layer edge appears once in \(A_{\ell m}\) and once in its transpose \(A_{m\ell}\). Thus the total number of edges is not the number of 1s in the full matrix; it is half that number when the matrix is binary, symmetric, and has a zero diagonal.

Justification: With \(P\) nodes, each undirected edge is an unordered pair of distinct nodes. There are \(\binom{P}{2}=P(P-1)/2\) possible pairs. Partitioning those pairs by layer gives \(\sum_{\ell=1}^{L}p_\ell(p_\ell-1)/2\) possible within-layer edges and \(\sum_{\ell<m}p_\ell p_m\) possible cross-layer edges. These totals agree because $$ \sum_{\ell=1}^{L}\frac{p_\ell(p_\ell-1)}{2}+\sum_{\ell<m}p_\ell p_m =\frac{(\sum_{\ell=1}^{L}p_\ell)^2-\sum_{\ell=1}^{L}p_\ell}{2} =\frac{P(P-1)}{2}. $$

Precision Matrices as a Different Representation

A precision matrix is not an adjacency matrix. For a random vector \(X\) of \(P\) continuous variables with a multivariate Gaussian model \(X\sim N(\mu,\Sigma)\), the covariance matrix \(\Sigma\) is assumed positive definite, and the precision matrix is \(\Omega=\Sigma^{-1}\). It is symmetric and positive definite as well. Under the conventional Gaussian graphical-model definition, an undirected edge is present between distinct variables \(i\) and \(j\) when \(\Omega_{ij}\ne 0\). This definition concerns the off-diagonal support; diagonal entries are not edges.

Arrange \(\Omega\) in the same layer order used for \(A\). Its block \(\Omega_{\ell m}\) has dimension \(p_\ell\) by \(p_m\). Symmetry requires \(\Omega_{m\ell}=\Omega_{\ell m}^{\mathsf T}\). The diagonal blocks contain within-layer entries, and off-diagonal blocks contain cross-layer entries. In contrast to a binary adjacency matrix, precision entries are numerical parameters of the model. Their values depend on the variables’ scales and the model; they should not be read as binary edge indicators without first applying the stated nonzero-entry rule.

Worked Example: Reading the Blocks of a Precision Matrix

Consider a hypothetical Gaussian model for one RNA variable \(R\), one protein variable \(P\), and one metabolite variable \(M\), in that order, with precision matrix

$$ \Omega= \begin{pmatrix} 4&-1&0.5\\ -1&3&0\\ 0.5&0&2 \end{pmatrix}. $$

The diagonal blocks are the scalars \(\Omega_{\mathrm{RNA},\mathrm{RNA}}=4\), \(\Omega_{\mathrm{protein},\mathrm{protein}}=3\), and \(\Omega_{\mathrm{metabolite},\mathrm{metabolite}}=2\). The cross-layer blocks are \(\Omega_{\mathrm{RNA},\mathrm{protein}}=-1\), \(\Omega_{\mathrm{RNA},\mathrm{metabolite}}=0.5\), and \(\Omega_{\mathrm{protein},\mathrm{metabolite}}=0\), together with their transposed positions.

Under the Gaussian graph convention, the nonzero off-diagonal entries specify \(R\)--\(P\) and \(R\)--\(M\) edges, while there is no \(P\)--\(M\) edge. The matrix is symmetric. It is also strictly diagonally dominant with positive diagonal: the absolute off-diagonal sums in its three rows are \(1.5,1,\) and \(0.5\), respectively, each smaller than its diagonal entry \(4,3,\) or \(2\). A symmetric strictly diagonally dominant matrix with positive diagonal is positive definite, so this example satisfies the precision-matrix requirement. The entries are model parameters, not edge weights on the scale of a binary adjacency matrix.

The Gaussian assumption and positive definiteness matter when a matrix is being presented as a valid precision matrix. A symmetric array of numbers alone is not necessarily a precision matrix: it must be invertible and positive definite to be the inverse of a nonsingular covariance matrix. Likewise, a binary adjacency matrix need not be positive definite; it is an encoding of edges, not a covariance or precision parameter.

Checking an Encoding and Choosing a Representation

Worked Example: Checking Dimensions and Counting Edges

A hypothetical network has three layers with \(p_1=2\) RNA features, \(p_2=1\) protein feature, and \(p_3=2\) metabolites. Suppose there are two within-RNA edges? That is impossible with two nodes and a simple undirected graph, so instead suppose there is one within-RNA edge, one within-metabolite edge, and two cross-layer edges between RNA and protein, RNA and metabolite, or protein and metabolite.

The full adjacency matrix must have \(P=2+1+2=5\) rows and columns. Its diagonal blocks have dimensions \(2\) by \(2\), \(1\) by \(1\), and \(2\) by \(2\). The RNA-to-protein block is \(2\) by \(1\); the RNA-to-metabolite block is \(2\) by \(2\); and the protein-to-metabolite block is \(1\) by \(2\). Their reverse-direction blocks have the transposed dimensions.

The stated network has \(1+1+2=4\) undirected edges. Its symmetric binary adjacency matrix therefore has \(2(4)=8\) off-diagonal entries equal to 1. This gives a useful consistency check: if a constructed matrix has 7 such entries, an edge may be missing from one direction; if it has 10, an edge may have been counted twice in the edge list or an extra edge may have been added.

Several equivalent formats serve different purposes. An edge list is compact for a sparse network and can preserve labels directly, but it is less convenient for matrix calculations. A full adjacency matrix makes dimensions, symmetry, and block locations visible, but can be mostly zero when the network is sparse. A block adjacency matrix emphasizes within-layer versus cross-layer structure without changing the underlying graph. A precision matrix is appropriate when the network is defined through a specified Gaussian model; it carries parameter values and validity constraints beyond simple edge presence.

RepresentationWhat it recordsUseful check or limitation
Edge listPairs of node labels, optionally with stated weightsCheck that layer and feature labels are unambiguous; symmetric duplicates are usually unnecessary for an undirected list
Adjacency matrixPresence or specified weight of each node pairFor an undirected graph, check symmetry and the diagonal convention
Block adjacency matrixThe same adjacency information organized by layer pairsCheck each block’s dimensions against the numbers of variables in its two layers
Precision matrixGaussian-model parameters whose off-diagonal support defines edgesCheck symmetry and positive definiteness; do not equate its numerical values with binary adjacency entries

A practical diagnostic is to make a node table before constructing any matrix: give each node a unique label, its layer, and its position in the global order. Then verify that every edge-list endpoint appears in that table, that each block has the expected dimensions, and that an undirected matrix has matching transposed blocks. If self-edges are excluded, verify the diagonal convention too. These checks detect indexing mistakes; they do not establish that the network’s edges are scientifically valid.

Common Mistakes and Limits

  • Mixing node orderings. A matrix is interpretable only with a declared ordering. If rows use RNA–protein–metabolite order but columns use protein–RNA–metabolite order, apparent asymmetry or misplaced edges may result.
  • Counting a cross-layer edge twice. In a symmetric matrix, one undirected edge occupies two entries. Count it once by using one triangle or by using the layer-pair formula.
  • Treating a zero as proof of no biological relationship. A zero in an encoded adjacency matrix means no edge was included under that representation. A zero in a precision matrix means no edge under the specified Gaussian support convention. Neither statement proves the underlying biology has no relationship.
  • Calling every matrix a precision matrix. Precision matrices must satisfy model conditions such as symmetry and positive definiteness. An arbitrary binary adjacency matrix does not have to satisfy them.
  • Reading an edge as causal. The node-and-edge encoding specifies a network structure, not causal direction or intervention effects. Undirected edges have no arrow and do not, by themselves, identify a causal mechanism.

Layering is useful because it makes cross-modal organization explicit and supports checks on which relationships are within or between modalities. It does not remove limitations of the underlying measurements, sample alignment, model assumptions, or edge-selection procedure. A correctly assembled block matrix can faithfully encode a poor or uncertain network just as readily as a well-supported one.

Check Your Understanding

Answer each question, then compare your reasoning with the solutions.

  1. A network has 3 RNA variables and 2 protein variables. What are the dimensions of the RNA-to-protein block and the full adjacency matrix?
  2. An undirected binary adjacency matrix has 6 ones and a zero diagonal. How many edges does it encode?
  3. For layers of sizes \(2,1,2\), how many possible within-layer edges and how many possible cross-layer edges are there in a simple undirected graph?
  4. Why is a nonzero off-diagonal precision entry not the same thing as a binary adjacency value of 1?
  5. A proposed precision matrix is symmetric but has a zero eigenvalue. Can it be the precision matrix of a nonsingular multivariate Gaussian distribution? Explain.

Solutions. (1) The RNA-to-protein block has \(3\) rows and \(2\) columns, so it is \(3\) by \(2\). There are \(3+2=5\) nodes, so the full adjacency matrix is \(5\) by \(5\). (2) Each undirected edge contributes two symmetric off-diagonal ones, so the edge count is \(6/2=3\). (3) Within-layer possibilities are \(\binom{2}{2}+\binom{1}{2}+\binom{2}{2}=1+0+1=2\). Cross-layer possibilities are \(2(1)+2(2)+1(2)=2+4+2=8\). (4) A precision entry is a numerical model parameter; the binary adjacency records presence or absence. The graph convention uses whether the off-diagonal precision entry is zero or nonzero, not whether its value equals 1. (5) No. A precision matrix for a nonsingular multivariate Gaussian must be positive definite and therefore have strictly positive eigenvalues. A zero eigenvalue makes the matrix singular, so it cannot be the inverse of a nonsingular covariance matrix.

Clinical Biostats