ligandReceptorTest: ligandReceptorTest

Description Usage Arguments Value Examples

View source: R/ligandReceptor_analysis.R

Description

A function to perform ligand receptor analysis

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
ligandReceptorTest(
  sce,
  ligandReceptor_list,
  cluster,
  RNA_exprs_value = "minMax",
  use_alt_exp = TRUE,
  altExp_name = "ADT",
  altExp_exprs_value = "zi_minMax",
  num_permute = 1000,
  p_sig = 0.05
)

Arguments

sce

A singlecellexperiment object

ligandReceptor_list

A data.frame indicates the ligand receptor list

cluster

A vector indicates the cluster results

RNA_exprs_value

A character indicates which expression value for RNA in assayNames is used.

use_alt_exp

A logical vector indicates whether receptors expression will use alternative expression matrix to quantify.

altExp_name

A character indicates which expression matrix is used. by default is ADT .

altExp_exprs_value

A character indicates which expression value in assayNames is used.

num_permute

Number of permutation.

p_sig

A numeric indicates threshold of the pvalue significance

Value

A SingleCellExperiment object with ligand receptor results

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
data(lr_pair_subset, package = "CiteFuse")
data(sce_control_subset, package = "CiteFuse")

sce_control_subset <- normaliseExprs(sce = sce_control_subset,
altExp_name = "ADT",
transform = "zi_minMax")

sce_control_subset <- normaliseExprs(sce = sce_control_subset,
                              altExp_name = "none",
                              exprs_value = "logcounts",
                              transform = "minMax")

sce_control_subset <- ligandReceptorTest(sce = sce_control_subset,
                                  ligandReceptor_list = lr_pair_subset,
                                  cluster = sce_control_subset$SNF_W_louvain,
                                  RNA_exprs_value = "minMax",
                                  use_alt_exp = TRUE,
                                  altExp_name = "ADT",
                                  altExp_exprs_value = "zi_minMax",
                                  num_permute = 100)

CiteFuse documentation built on April 14, 2021, 6 p.m.