... | ... |
@@ -24,10 +24,10 @@ export(featureModuleLookup) |
24 | 24 |
export(featureModuleTable) |
25 | 25 |
export(geneSetEnrich) |
26 | 26 |
export(logLikelihood) |
27 |
-export(logLikelihood.celda_C) |
|
28 |
-export(logLikelihood.celda_CG) |
|
29 |
-export(logLikelihood.celda_G) |
|
30 | 27 |
export(logLikelihoodHistory) |
28 |
+export(logLikelihoodcelda_C) |
|
29 |
+export(logLikelihoodcelda_CG) |
|
30 |
+export(logLikelihoodcelda_G) |
|
31 | 31 |
export(matrixNames) |
32 | 32 |
export(moduleHeatmap) |
33 | 33 |
export(normalizeCounts) |
... | ... |
@@ -38,9 +38,9 @@ export(plotDimReduceFeature) |
38 | 38 |
export(plotDimReduceGrid) |
39 | 39 |
export(plotDimReduceModule) |
40 | 40 |
export(plotGridSearchPerplexity) |
41 |
-export(plotGridSearchPerplexity.celda_C) |
|
42 |
-export(plotGridSearchPerplexity.celda_CG) |
|
43 |
-export(plotGridSearchPerplexity.celda_G) |
|
41 |
+export(plotGridSearchPerplexitycelda_C) |
|
42 |
+export(plotGridSearchPerplexitycelda_CG) |
|
43 |
+export(plotGridSearchPerplexitycelda_G) |
|
44 | 44 |
export(plotHeatmap) |
45 | 45 |
export(recodeClusterY) |
46 | 46 |
export(recodeClusterZ) |
... | ... |
@@ -53,9 +53,9 @@ export(sampleLabel) |
53 | 53 |
export(selectBestModel) |
54 | 54 |
export(semiPheatmap) |
55 | 55 |
export(simulateCells) |
56 |
-export(simulateCells.celda_C) |
|
57 |
-export(simulateCells.celda_CG) |
|
58 |
-export(simulateCells.celda_G) |
|
56 |
+export(simulateCellscelda_C) |
|
57 |
+export(simulateCellscelda_CG) |
|
58 |
+export(simulateCellscelda_G) |
|
59 | 59 |
export(simulateContaminatedMatrix) |
60 | 60 |
export(subsetCeldaList) |
61 | 61 |
export(topRank) |
... | ... |
@@ -77,22 +77,40 @@ exportMethods(perplexity) |
77 | 77 |
exportMethods(resList) |
78 | 78 |
exportMethods(runParams) |
79 | 79 |
exportMethods(sampleLabel) |
80 |
-import(MAST, except = c(combine)) |
|
81 |
-import(RColorBrewer) |
|
82 | 80 |
import(Rcpp) |
83 | 81 |
import(RcppEigen) |
84 |
-import(SummarizedExperiment, except = c(shift, rowRanges)) |
|
85 |
-import(data.table) |
|
86 | 82 |
import(foreach) |
83 |
+import(ggplot2) |
|
87 | 84 |
import(grDevices) |
88 | 85 |
import(graphics) |
89 | 86 |
import(grid) |
90 |
-import(gridExtra) |
|
91 |
-import(gridExtra, except = c(combine)) |
|
92 | 87 |
import(gtable) |
93 |
-import(matrixStats, except = c(count)) |
|
94 |
-import(plyr) |
|
95 |
-import(scales) |
|
88 |
+import(stats) |
|
89 |
+import(umap) |
|
90 |
+importFrom(MAST,FromMatrix) |
|
91 |
+importFrom(MAST,summary) |
|
92 |
+importFrom(MAST,zlm) |
|
93 |
+importFrom(MCMCprecision,fit_dirichlet) |
|
94 |
+importFrom(RColorBrewer,brewer.pal) |
|
95 |
+importFrom(Rtsne,Rtsne) |
|
96 |
+importFrom(S4Vectors,mcols) |
|
97 |
+importFrom(SummarizedExperiment,assay) |
|
98 |
+importFrom(SummarizedExperiment,assayNames) |
|
99 |
+importFrom(SummarizedExperiment,colData) |
|
100 |
+importFrom(data.table,as.data.table) |
|
101 |
+importFrom(digest,digest) |
|
102 |
+importFrom(doParallel,registerDoParallel) |
|
103 |
+importFrom(enrichR,enrichr) |
|
104 |
+importFrom(ggrepel,geom_text_repel) |
|
105 |
+importFrom(gridExtra,grid.arrange) |
|
106 |
+importFrom(matrixStats,logSumExp) |
|
107 |
+importFrom(methods,.hasSlot) |
|
108 |
+importFrom(methods,is) |
|
109 |
+importFrom(methods,new) |
|
110 |
+importFrom(plyr,mapvalues) |
|
111 |
+importFrom(reshape2,melt) |
|
112 |
+importFrom(scales,dscale) |
|
113 |
+importFrom(stringi,stri_list2matrix) |
|
96 | 114 |
useDynLib(celda,"_colSumByGroup") |
97 | 115 |
useDynLib(celda,"_colSumByGroupChange") |
98 | 116 |
useDynLib(celda,"_colSumByGroup_numeric") |
... | ... |
@@ -23,6 +23,7 @@ |
23 | 23 |
#' gse <- geneSetEnrich(counts, |
24 | 24 |
#' cm, |
25 | 25 |
#' databases = c('GO_Biological_Process_2018','GO_Molecular_Function_2018')) |
26 |
+#' @importFrom enrichR enrichr |
|
26 | 27 |
#' @export |
27 | 28 |
geneSetEnrich <- function(counts, celdaModel, databases, fdr = 0.05) { |
28 | 29 |
#check for correct celda object |
29 | 30 |
similarity index 88% |
30 | 31 |
rename from man/logLikelihood.celda_C.Rd |
31 | 32 |
rename to man/logLikelihoodcelda_C.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_C.R |
3 |
-\name{logLikelihood.celda_C} |
|
4 |
-\alias{logLikelihood.celda_C} |
|
3 |
+\name{logLikelihoodcelda_C} |
|
4 |
+\alias{logLikelihoodcelda_C} |
|
5 | 5 |
\title{Calculate Celda_C log likelihood} |
6 | 6 |
\usage{ |
7 |
-logLikelihood.celda_C(counts, sampleLabel, z, K, alpha, beta) |
|
7 |
+logLikelihoodcelda_C(counts, sampleLabel, z, K, alpha, beta) |
|
8 | 8 |
} |
9 | 9 |
\arguments{ |
10 | 10 |
\item{counts}{Integer matrix. Rows represent features and columns represent |
... | ... |
@@ -34,7 +34,7 @@ Calculates the log likelihood for user-provided cell population |
34 | 34 |
} |
35 | 35 |
\examples{ |
36 | 36 |
data(celdaCSim) |
37 |
-loglik <- logLikelihood.celda_C(celdaCSim$counts, |
|
37 |
+loglik <- logLikelihoodcelda_C(celdaCSim$counts, |
|
38 | 38 |
sampleLabel = celdaCSim$sampleLabel, |
39 | 39 |
z = celdaCSim$z, |
40 | 40 |
K = celdaCSim$K, |
41 | 41 |
similarity index 91% |
42 | 42 |
rename from man/logLikelihood.celda_CG.Rd |
43 | 43 |
rename to man/logLikelihoodcelda_CG.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_CG.R |
3 |
-\name{logLikelihood.celda_CG} |
|
4 |
-\alias{logLikelihood.celda_CG} |
|
3 |
+\name{logLikelihoodcelda_CG} |
|
4 |
+\alias{logLikelihoodcelda_CG} |
|
5 | 5 |
\title{Calculate Celda_CG log likelihood} |
6 | 6 |
\usage{ |
7 |
-logLikelihood.celda_CG(counts, sampleLabel, z, y, K, L, alpha, beta, delta, |
|
7 |
+logLikelihoodcelda_CG(counts, sampleLabel, z, y, K, L, alpha, beta, delta, |
|
8 | 8 |
gamma) |
9 | 9 |
} |
10 | 10 |
\arguments{ |
... | ... |
@@ -45,7 +45,7 @@ Calculates the log likelihood for user-provided cell population |
45 | 45 |
} |
46 | 46 |
\examples{ |
47 | 47 |
data(celdaCGSim) |
48 |
-loglik <- logLikelihood.celda_CG(celdaCGSim$counts, |
|
48 |
+loglik <- logLikelihoodcelda_CG(celdaCGSim$counts, |
|
49 | 49 |
sampleLabel = celdaCGSim$sampleLabel, |
50 | 50 |
z = celdaCGSim$z, |
51 | 51 |
y = celdaCGSim$y, |
52 | 52 |
similarity index 89% |
53 | 53 |
rename from man/logLikelihood.celda_G.Rd |
54 | 54 |
rename to man/logLikelihoodcelda_G.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_G.R |
3 |
-\name{logLikelihood.celda_G} |
|
4 |
-\alias{logLikelihood.celda_G} |
|
3 |
+\name{logLikelihoodcelda_G} |
|
4 |
+\alias{logLikelihoodcelda_G} |
|
5 | 5 |
\title{Calculate Celda_G log likelihood} |
6 | 6 |
\usage{ |
7 |
-logLikelihood.celda_G(counts, y, L, beta, delta, gamma) |
|
7 |
+logLikelihoodcelda_G(counts, y, L, beta, delta, gamma) |
|
8 | 8 |
} |
9 | 9 |
\arguments{ |
10 | 10 |
\item{counts}{Integer matrix. Rows represent features and columns represent |
... | ... |
@@ -34,7 +34,7 @@ Calculates the log likelihood for user-provided feature module |
34 | 34 |
} |
35 | 35 |
\examples{ |
36 | 36 |
data(celdaGSim) |
37 |
-loglik <- logLikelihood.celda_G(celdaGSim$counts, |
|
37 |
+loglik <- logLikelihoodcelda_G(celdaGSim$counts, |
|
38 | 38 |
y = celdaGSim$y, |
39 | 39 |
L = celdaGSim$L, |
40 | 40 |
beta = celdaGSim$beta, |
41 | 41 |
similarity index 84% |
42 | 42 |
rename from man/plotGridSearchPerplexity.celda_C.Rd |
43 | 43 |
rename to man/plotGridSearchPerplexitycelda_C.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/model_performance.R |
3 |
-\name{plotGridSearchPerplexity.celda_C} |
|
4 |
-\alias{plotGridSearchPerplexity.celda_C} |
|
3 |
+\name{plotGridSearchPerplexitycelda_C} |
|
4 |
+\alias{plotGridSearchPerplexitycelda_C} |
|
5 | 5 |
\title{Plot perplexity as a function of K from celda_C models} |
6 | 6 |
\usage{ |
7 |
-plotGridSearchPerplexity.celda_C(celdaList, sep) |
|
7 |
+plotGridSearchPerplexitycelda_C(celdaList, sep) |
|
8 | 8 |
} |
9 | 9 |
\arguments{ |
10 | 10 |
\item{celdaList}{Object of class 'celdaList'.} |
11 | 11 |
similarity index 84% |
12 | 12 |
rename from man/plotGridSearchPerplexity.celda_CG.Rd |
13 | 13 |
rename to man/plotGridSearchPerplexitycelda_CG.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/model_performance.R |
3 |
-\name{plotGridSearchPerplexity.celda_CG} |
|
4 |
-\alias{plotGridSearchPerplexity.celda_CG} |
|
3 |
+\name{plotGridSearchPerplexitycelda_CG} |
|
4 |
+\alias{plotGridSearchPerplexitycelda_CG} |
|
5 | 5 |
\title{Plot perplexity as a function of K and L from celda_CG models} |
6 | 6 |
\usage{ |
7 |
-plotGridSearchPerplexity.celda_CG(celdaList, sep) |
|
7 |
+plotGridSearchPerplexitycelda_CG(celdaList, sep) |
|
8 | 8 |
} |
9 | 9 |
\arguments{ |
10 | 10 |
\item{celdaList}{Object of class 'celdaList'.} |
11 | 11 |
similarity index 84% |
12 | 12 |
rename from man/plotGridSearchPerplexity.celda_G.Rd |
13 | 13 |
rename to man/plotGridSearchPerplexitycelda_G.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/model_performance.R |
3 |
-\name{plotGridSearchPerplexity.celda_G} |
|
4 |
-\alias{plotGridSearchPerplexity.celda_G} |
|
3 |
+\name{plotGridSearchPerplexitycelda_G} |
|
4 |
+\alias{plotGridSearchPerplexitycelda_G} |
|
5 | 5 |
\title{Plot perplexity as a function of L from a celda_G model} |
6 | 6 |
\usage{ |
7 |
-plotGridSearchPerplexity.celda_G(celdaList, sep) |
|
7 |
+plotGridSearchPerplexitycelda_G(celdaList, sep) |
|
8 | 8 |
} |
9 | 9 |
\arguments{ |
10 | 10 |
\item{celdaList}{Object of class 'celdaList'.} |
11 | 11 |
similarity index 93% |
12 | 12 |
rename from man/simulateCells.celda_C.Rd |
13 | 13 |
rename to man/simulateCellscelda_C.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_C.R |
3 |
-\name{simulateCells.celda_C} |
|
4 |
-\alias{simulateCells.celda_C} |
|
3 |
+\name{simulateCellscelda_C} |
|
4 |
+\alias{simulateCellscelda_C} |
|
5 | 5 |
\title{Simulate cells from the celda_C model} |
6 | 6 |
\usage{ |
7 |
-simulateCells.celda_C(model, S = 5, CRange = c(50, 100), |
|
7 |
+simulateCellscelda_C(model, S = 5, CRange = c(50, 100), |
|
8 | 8 |
NRange = c(500, 1000), G = 100, K = 5, alpha = 1, beta = 1, |
9 | 9 |
...) |
10 | 10 |
} |
11 | 11 |
similarity index 94% |
12 | 12 |
rename from man/simulateCells.celda_CG.Rd |
13 | 13 |
rename to man/simulateCellscelda_CG.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_CG.R |
3 |
-\name{simulateCells.celda_CG} |
|
4 |
-\alias{simulateCells.celda_CG} |
|
3 |
+\name{simulateCellscelda_CG} |
|
4 |
+\alias{simulateCellscelda_CG} |
|
5 | 5 |
\title{Simulate cells from the celda_CG model} |
6 | 6 |
\usage{ |
7 |
-simulateCells.celda_CG(model, S = 5, CRange = c(50, 100), |
|
7 |
+simulateCellscelda_CG(model, S = 5, CRange = c(50, 100), |
|
8 | 8 |
NRange = c(500, 1000), G = 100, K = 5, L = 10, alpha = 1, |
9 | 9 |
beta = 1, gamma = 5, delta = 1, ...) |
10 | 10 |
} |
11 | 11 |
similarity index 92% |
12 | 12 |
rename from man/simulateCells.celda_G.Rd |
13 | 13 |
rename to man/simulateCellscelda_G.Rd |
... | ... |
@@ -1,10 +1,10 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/celda_G.R |
3 |
-\name{simulateCells.celda_G} |
|
4 |
-\alias{simulateCells.celda_G} |
|
3 |
+\name{simulateCellscelda_G} |
|
4 |
+\alias{simulateCellscelda_G} |
|
5 | 5 |
\title{Simulate cells from the celda_G model} |
6 | 6 |
\usage{ |
7 |
-simulateCells.celda_G(model, C = 100, NRange = c(500, 1000), G = 100, |
|
7 |
+simulateCellscelda_G(model, C = 100, NRange = c(500, 1000), G = 100, |
|
8 | 8 |
L = 10, beta = 1, gamma = 5, delta = 1, ...) |
9 | 9 |
} |
10 | 10 |
\arguments{ |
11 | 11 |
deleted file mode 100644 |
... | ... |
@@ -1,54 +0,0 @@ |
1 |
-library(celda) |
|
2 |
-context("Testing recursiveSplits") |
|
3 |
- |
|
4 |
-# celdaCGSim <- simulateCells("celda_CG", K = 5, L = 10) |
|
5 |
-# |
|
6 |
-# test_that(desc = "Testing recursiveSplitModule", { |
|
7 |
-# moduleSplit <- recursiveSplitModule( |
|
8 |
-# celdaCGSim$counts, |
|
9 |
-# initialL = 8, |
|
10 |
-# maxL = 15, |
|
11 |
-# tempK = 5, |
|
12 |
-# zInit = NULL) |
|
13 |
-# expect_true(is(moduleSplit, "celdaList")) |
|
14 |
-# moduleSplit <- recursiveSplitModule( |
|
15 |
-# celdaCGSim$counts, |
|
16 |
-# initialL = 8, |
|
17 |
-# maxL = 15, |
|
18 |
-# tempK = NULL, |
|
19 |
-# zInit = celdaCGSim$z) |
|
20 |
-# expect_true(is(moduleSplit, "celdaList")) |
|
21 |
-# moduleSplit <- recursiveSplitModule( |
|
22 |
-# celdaCGSim$counts, |
|
23 |
-# initialL = 8, |
|
24 |
-# maxL = 15, |
|
25 |
-# tempK = NULL, |
|
26 |
-# zInit = NULL) |
|
27 |
-# expect_true(is(moduleSplit, "celdaList")) |
|
28 |
-# plotGridSearchPerplexity(moduleSplit) |
|
29 |
-# }) |
|
30 |
-# |
|
31 |
-# test_that(desc = "Testing recursiveSplitCell", { |
|
32 |
-# cellSplit <- recursiveSplitCell( |
|
33 |
-# celdaCGSim$counts, |
|
34 |
-# initialK = 3, |
|
35 |
-# maxK = 8, |
|
36 |
-# tempL = 20, |
|
37 |
-# yInit = NULL) |
|
38 |
-# expect_true(is(cellSplit, "celdaList")) |
|
39 |
-# cellSplit <- recursiveSplitCell( |
|
40 |
-# celdaCGSim$counts, |
|
41 |
-# initialK = 3, |
|
42 |
-# maxK = 8, |
|
43 |
-# tempL = NULL, |
|
44 |
-# yInit = celdaCGSim$y) |
|
45 |
-# expect_true(is(cellSplit, "celdaList")) |
|
46 |
-# cellSplit <- recursiveSplitCell( |
|
47 |
-# celdaCGSim$counts, |
|
48 |
-# initialK = 3, |
|
49 |
-# maxK = 8, |
|
50 |
-# tempL = NULL, |
|
51 |
-# yInit = NULL) |
|
52 |
-# expect_true(is(cellSplit, "celdaList")) |
|
53 |
-# plotGridSearchPerplexity(cellSplit) |
|
54 |
-# }) |