Compute a Probabilistic Boolean Network (PBN) for each cluster or each cell
Source:R/computePbn.R
computePbnByCluster.RdAfter running performViper, this can be run to produce a
PBN with the identity function probability for each node relative to the
VIPER normalised enrichment score (NES) for cell. For computePbnByCluster,
the median NES for all cells in that cluster will be used.
Arguments
- ingres.object
An
ingresobject with a non-null VIPER slot.- range
A vector representing the range to which the NES are to be re-scaled.
range[1]+range[2] == 0should be TRUE. Defaults to [-1, 1]
Value
An ingres object with
the cluster.pbn or the single.cell.pbn slot filled
Functions
computePbnByCluster: Compute a Probabilistic Boolean Network (PBN) for each clustercomputePbnBySingleCell: Compute a Probabilistic Boolean Network (PBN) for each cell
Examples
# Create an ingres object with viper slot
ing <- createExampleIngresObjectWithViper()
#> Error in createExampleIngresObjectWithViper(): could not find function "createExampleIngresObjectWithViper"
ing <- computePbnByCluster(ing)
#> Error in eval_tidy(xs[[j]], mask): object 'ing' not found
head(ing@cluster.pbn)
#> Error in head(ing@cluster.pbn): object 'ing' not found
ing <- computePbnBySingleCell(ing)
#> Error in eval_tidy(xs[[j]], mask): object 'ing' not found
head(ing@single.cell.pbn)
#> Error in head(ing@single.cell.pbn): object 'ing' not found
# Restrict range to (-0.5, 0.5)
ing <- computePbnByCluster(ing, range = c(-0.5, 0.5))
#> Error in eval_tidy(xs[[j]], mask): object 'ing' not found
head(ing@cluster.pbn)
#> Error in head(ing@cluster.pbn): object 'ing' not found
ing <- computePbnBySingleCell(ing, range = c(-0.5, 0.5))
#> Error in eval_tidy(xs[[j]], mask): object 'ing' not found
head(ing@single.cell.pbn)
#> Error in head(ing@single.cell.pbn): object 'ing' not found