plotHigherOrderSequence: plotHigherOrderSequence

Description Usage Arguments Value Examples

Description

the plotHigherOrderSequence function plots weighted higher order statistic vectors (stored in higherOrderSequence) as line plots

Usage

1
2
3
4
5
6
7
plotHigherOrderSequence(
  scHOT,
  gene,
  positionType = NULL,
  branches = NULL,
  positionColData = NULL
)

Arguments

scHOT

A scHOT object with higherOrderSequence in scHOT_output slot

gene

is either a logical vector matching rows of entries in wcorsList, or a character of a gene

positionType

A string indicates the position type, either trajectory or spatial

branches

A character indicates that the colnames stored the branch information in colData (for trajectory type of data)

positionColData

A vector indicates column names of colData that stored the postion informaton (for spatial type of data)

Value

ggplot object with line plots

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
data(liver)

scHOT_traj <- scHOT_buildFromMatrix(
mat = liver$liver_branch_hep,
cellData = list(pseudotime = liver$liver_pseudotime_hep),
positionType = "trajectory",
positionColData = "pseudotime")
scHOT_traj
plotColouredExpression(scHOT_traj, c("Cdt1","Top2a"), n = 5)

scHOT_traj <- scHOT_addTestingScaffold(scHOT_traj,
t(as.matrix(c("Cdt1", "Top2a"))))
scHOT_traj <- scHOT_setWeightMatrix(scHOT_traj,
positionColData = c("pseudotime"),
positionType = "trajectory",
nrow.out = NULL,
span = 0.25)
scHOT_traj <- scHOT_calculateGlobalHigherOrderFunction(scHOT_traj,
                                                      higherOrderFunction =
                                                      weightedSpearman,
                                                     higherOrderFunctionType =
                                                     "weighted")

scHOT_traj <- scHOT_calculateHigherOrderTestStatistics(scHOT_traj,
                                                      higherOrderSummaryFunction =
                                                      sd)

slot(scHOT_traj, "scHOT_output")
plotHigherOrderSequence(scHOT_traj, c("Cdt1_Top2a"))

scHOT documentation built on Nov. 8, 2020, 5:06 p.m.