Phemd-methods: Setter function for protein / gene markers

Description Usage Arguments Value Examples

Description

Setter function for protein / gene markers

Setter function for stored expression data

Setter function for single-cell expression data aggregated from multiple samples

Setter function for indices of cells subsampled from each sample during aggregation

Setter function for boolean denoting whether cells were subsampled from each sample during aggregation

Setter function for Monocle2 CellDataSet object for experiment

Setter function for Seurat object for experiment

Setter function for phate object for experiment

Setter function for cell subtype frequencies of each single-cell sample

Setter function for batch IDs of each single-cell sample

Setter function for EMD ground distance matrix

Usage

 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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
selectMarkers(obj) <- value

## S4 replacement method for signature 'Phemd'
selectMarkers(obj) <- value

rawExpn(obj) <- value

## S4 replacement method for signature 'Phemd'
rawExpn(obj) <- value

pooledCells(obj) <- value

## S4 replacement method for signature 'Phemd'
pooledCells(obj) <- value

subsampledIdx(obj) <- value

## S4 replacement method for signature 'Phemd'
subsampledIdx(obj) <- value

subsampledBool(obj) <- value

## S4 replacement method for signature 'Phemd'
subsampledBool(obj) <- value

monocleInfo(obj) <- value

## S4 replacement method for signature 'Phemd'
monocleInfo(obj) <- value

seuratInfo(obj) <- value

## S4 replacement method for signature 'Phemd'
seuratInfo(obj) <- value

phateInfo(obj) <- value

## S4 replacement method for signature 'Phemd'
phateInfo(obj) <- value

celltypeFreqs(obj) <- value

## S4 replacement method for signature 'Phemd'
celltypeFreqs(obj) <- value

batchIDs(obj) <- value

## S4 replacement method for signature 'Phemd'
batchIDs(obj) <- value

GDM(obj) <- value

## S4 replacement method for signature 'Phemd'
GDM(obj) <- value

Arguments

obj

A Phemd object

value

Assignment object

Value

Updated Phemd object

Updated Phemd object

Updated Phemd object

Updated Phemd object

Updated Phemd object

Updated Phemd object containing Seurat object

Updated Phemd object containing phate object

Updated Phemd object

Updated Phemd object

Updated Phemd object

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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
new_genes <- all_genes
new_genes[1] <- 'IL2R'
selectMarkers(phemdObj) <- new_genes

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
new_expn_data <- all_expn_data
new_expn_data <- lapply(new_expn_data, function(x) {log2(x+1)})
rawExpn(phemdObj) <- new_expn_data

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
aggregated_data <- t(do.call(rbind,all_expn_data))
pooledCells(phemdObj) <- aggregated_data

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
subsampledIdxList<- rep(list(1:10), length(all_expn_data)) #subsampled cells 1-10 from each sample
subsampledIdx(phemdObj) <- subsampledIdxList

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
subsampledBool(phemdObj) <- TRUE

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
mydata <- pooledCells(phemdObj)
myCellDataSet <- newCellDataSet(mydata,phenoData=NULL, expressionFamily=VGAM::negbinomial.size())
monocleInfo(phemdObj) <- myCellDataSet

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
my_seuratObj <- Seurat::CreateSeuratObject(counts = t(all_expn_data[[1]]), project = "A")
seuratInfo(phemdObj) <- my_seuratObj

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
#my_phateObj <- phateR::phate(all_expn_data[[1]])
phateInfo(phemdObj) <- list()

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
myCellTypeFreqs <- matrix(rexp(length(all_expn_data)*10, rate=.1), ncol=10)
myCellTypeFreqs <- apply(myCellTypeFreqs, 1, function(x) {x / sum(x)})
celltypeFreqs(phemdObj) <- myCellTypeFreqs

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
my_seuratObj <- Seurat::CreateSeuratObject(counts = t(all_expn_data[[1]]), project = "A")
seuratInfo(phemdObj) <- my_seuratObj
batchIDs(phemdObj) <- rep('A', length(all_expn_data))

phemdObj <- createDataObj(all_expn_data, all_genes, as.character(snames_data))
cluster_locs <- 1:10
myGDM <- as.matrix(dist(cluster_locs))
GDM(phemdObj) <- myGDM

phemd documentation built on Nov. 8, 2020, 8:15 p.m.