Infer Receptor Activity from NeighbourNet TF–Target Networks
receptor.activity.RdThis function infers receptor, transcription factor (TF), and target activity by combining a receptor–TF prior model (personalised PageRank) with NeighbourNet TF–target co-expression networks. Activity can be evaluated at the per-cell level or on meta-networks, and can be optionally filtered by receptor expression and prior gene regulatory network (GRN) evidence.
Usage
receptor.activity(
seurat.obj,
i = NULL,
meta.network = FALSE,
cutoff = NULL,
check.receptor.expression = TRUE,
check.gr.evidence = TRUE,
t = 2,
p = NULL,
scale.ppr = TRUE,
scale.network = TRUE,
as.tfs = c("predictors", "responses"),
receptors = NULL,
tfs = NULL,
targets = NULL,
receptor.activity = c("cprod", "dist")
)Arguments
- seurat.obj
A
Seuratobject with aNNet.modlist stored in themiscslot. This list is created byrun.nn.reg. To optionally infer receptor activity on meta-networks (setmeta.network = TRUE), theNNet.modshould be updated by a subsequent run ofbuild.meta.network.- i
Optional index of cells or meta-network components for which to compute receptor activity. If
NULL, usesNNet.mod$cellsfor per-cell networks or all meta-network components whenmeta.network = TRUE.- meta.network
A logical indicating whether to compute activity on NeighbourNet meta-networks instead of per-cell networks. If
TRUE, the"meta.network"assay is used and each component is treated as a meta-cell. Default isFALSE.- cutoff
A numeric value specifying the p-value threshold to prune insignificant co-expression values. If
NULL, the default value is taken fromNNet.mod$defaults.- check.receptor.expression
A logical indicating whether receptor activity should be down-weighted by receptor expression. Default is
TRUE.- check.gr.evidence
A logical indicating whether TF–target edges should be filtered by prior GRN evidence from
get.gr.adj. Default isTRUE.- t
A numeric value passed to
get.gr.adjthat controls the depth or order of TF–target adjacency used as prior GRN evidence. Default is2.- p
A numeric value passed to
get.prior.modelspecifying the quantile threshold for pruning the PPR matrix. IfNULL, the default threshold stored inreceptor.ppr$ltfis used. Default isNULL.- scale.ppr
A logical indicating whether to normalise the receptor–TF prior model (PageRank matrix) by receptor-wise norms. Default is
TRUE.- scale.network
A logical indicating whether to normalise the TF–target co-expression network by target-wise norms before computing activity. Default is
TRUE.- as.tfs
A character string indicating whether TFs are encoded as
"predictors"(columns) or"responses"(rows) in the NeighbourNet networks. Default is"predictors".- receptors
A character vector of receptor genes to include. If
NULL, all receptors present in the prior model returned byget.prior.modelare used.- tfs
A character vector of TFs to include. If
NULL, TFs are taken from the default gene set stored inNNet.mod$defaults.- targets
A character vector of target genes to include. If
NULL, targets are taken from the default gene set stored inNNet.mod$defaults.- receptor.activity
A character string specifying how receptor–TF and TF–target information should be combined. Options are
"cprod"(cross-product aggregration that measures cosine similarity, default) and"dist"(max-over-path aggregation).
Value
If multiple cells or meta-network components are requested (length(i) > 1
or i = NULL), the function returns a list with:
- receptor.act
A matrix of receptor activity scores (receptors x cells/components).
- tf.act
A matrix of TF activity scores (TFs x cells/components).
- target.act
A matrix of target activity scores (targets x cells/components).
If a single cell or component is requested, the function returns a list with:
- act.mat
A receptor–target activity matrix (receptors x targets).
- ppr
The receptor–TF prior used after any scaling and expression weighting.
- network
The TF–target network used for activity computation.
Details
This function integrates three hierarchical components to infer receptor activity:
(i) a receptor–TF prior model obtained from get.prior.model,
(ii) TF–target co-expression networks derived from NeighbourNet, and
(iii) optional TF–target adjacency matrices from get.gr.adj as
prior gene regulatory network (GRN) evidence. Together, these components
define a receptor–TF–target signalling cascade that quantifies how upstream
receptors potentially influence downstream target genes through TFs.
For each cell or meta-network component, the receptor–TF prior model encodes the probability of regulatory transmission from receptors to TF, while the TF–target network represents local co-expression relationships inferred by NeighbourNet. Receptor activity is computed by aggregating these two layers to estimate receptor influence on downstream targets, mediated by TFs. The resulting matrices describe receptor-, TF-, and target-level activity for each cell or component, providing an interpretable summary of upstream signalling dynamics.
Activity can be inferred from per-cell networks (default) or from
meta-networks when meta.network = TRUE. The arguments scale.ppr and
scale.network apply L2-normalisation to the prior model and
co-expression network respectively, reducing the influence of highly connected
nodes and ensuring comparable contribution across genes. The options
check.receptor.expression and check.gr.evidence introduce two
filters on receptor activity : the first enforces that receptors must be transcriptionally
detected, while the second prunes TF–target co-expression to those
supported by prior GRN knowledge.
The argument receptor.activity controls how the two layers are
combined: "cprod" performs a cross-product aggregation equivalent to
measuring cosine similarity between receptor–TF and TF–target profiles,
while "dist" applies a max-over-path operation that highlights the
strongest possible receptor–target link through any intermediate TF.
Examples
# Per-cell receptor activity using default settings
act <- receptor.activity(seurat.obj)
#> Error: object 'seurat.obj' not found
# Meta-network receptor activity for the first three components
act <- receptor.activity(
seurat.obj,
meta.network = TRUE,
i = 1:3
)
#> Error: object 'seurat.obj' not found