... | ... |
@@ -1,12 +1,13 @@ |
1 | 1 |
Package: GSVA |
2 |
-Version: 1.35.3 |
|
2 |
+Version: 1.35.4 |
|
3 | 3 |
Title: Gene Set Variation Analysis for microarray and RNA-seq data |
4 | 4 |
Authors@R: c(person("Justin", "Guinney", role=c("aut", "cre"), email="justin.guinney@sagebase.org"), |
5 | 5 |
person("Robert", "Castelo", role="aut", email="robert.castelo@upf.edu"), |
6 | 6 |
person("Joan", "Fernandez", role="ctb", email="joanfernandez1331@gmail.com")) |
7 | 7 |
Depends: R (>= 3.5.0) |
8 |
-Imports: methods, BiocGenerics, Biobase, GSEABase (>= 1.17.4), |
|
9 |
- parallel, BiocParallel, geneplotter, shiny, shinythemes |
|
8 |
+Imports: methods, BiocGenerics, Biobase, SummarizedExperiment, |
|
9 |
+ SingleCellExperiment, GSEABase (>= 1.17.4), parallel, |
|
10 |
+ BiocParallel, shiny, shinythemes |
|
10 | 11 |
Suggests: limma, RColorBrewer, genefilter, edgeR, snow, GSVAdata |
11 | 12 |
Description: Gene Set Variation Analysis (GSVA) is a non-parametric, unsupervised method for estimating variation of gene set enrichment through the samples of a expression data set. GSVA performs a change in coordinate systems, transforming the data from a gene by sample matrix to a gene-set by sample matrix, thereby allowing the evaluation of pathway enrichment for each sample. This new matrix of GSVA enrichment scores facilitates applying standard analytical methods like functional enrichment, survival analysis, clustering, CNV-pathway analysis or cross-tissue pathway analysis, in a pathway-centric manner. |
12 | 13 |
License: GPL (>= 2) |
... | ... |
@@ -5,6 +5,8 @@ import(BiocGenerics) |
5 | 5 |
import(shiny) |
6 | 6 |
|
7 | 7 |
importClassesFrom(Biobase, ExpressionSet) |
8 |
+importClassesFrom(SummarizedExperiment, SummarizedExperiment) |
|
9 |
+importClassesFrom(SingleCellExperiment, SingleCellExperiment) |
|
8 | 10 |
importClassesFrom(GSEABase, GeneSetCollection) |
9 | 11 |
|
10 | 12 |
importMethodsFrom(Biobase, featureNames, |
... | ... |
@@ -37,7 +39,6 @@ importFrom(BiocParallel, SerialParam, |
37 | 39 |
MulticoreParam, |
38 | 40 |
multicoreWorkers, |
39 | 41 |
bpnworkers) |
40 |
-importFrom(geneplotter, multidensity) |
|
41 | 42 |
importFrom(shinythemes, shinytheme) |
42 | 43 |
|
43 | 44 |
exportMethods(gsva, |
... | ... |
@@ -13,7 +13,6 @@ setMethod("gsva", signature(expr="ExpressionSet", gset.idx.list="list"), |
13 | 13 |
min.sz=1, |
14 | 14 |
max.sz=Inf, |
15 | 15 |
parallel.sz=1L, |
16 |
- parallel.type="SOCK", |
|
17 | 16 |
mx.diff=TRUE, |
18 | 17 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
19 | 18 |
ssgsea.norm=TRUE, |
... | ... |
@@ -63,8 +62,7 @@ setMethod("gsva", signature(expr="ExpressionSet", gset.idx.list="list"), |
63 | 62 |
} |
64 | 63 |
|
65 | 64 |
eSco <- .gsva(exprs(expr), mapped.gset.idx.list, method, kcdf, rnaseq, abs.ranking, |
66 |
- parallel.sz, parallel.type, mx.diff, tau, kernel, ssgsea.norm, |
|
67 |
- verbose, BPPARAM) |
|
65 |
+ parallel.sz, mx.diff, tau, kernel, ssgsea.norm, verbose, BPPARAM) |
|
68 | 66 |
|
69 | 67 |
eScoEset <- new("ExpressionSet", exprs=eSco, phenoData=phenoData(expr), |
70 | 68 |
experimentData=experimentData(expr), annotation="") |
... | ... |
@@ -82,7 +80,6 @@ setMethod("gsva", signature(expr="ExpressionSet", gset.idx.list="GeneSetCollecti |
82 | 80 |
min.sz=1, |
83 | 81 |
max.sz=Inf, |
84 | 82 |
parallel.sz=1L, |
85 |
- parallel.type="SOCK", |
|
86 | 83 |
mx.diff=TRUE, |
87 | 84 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
88 | 85 |
ssgsea.norm=TRUE, |
... | ... |
@@ -138,8 +135,7 @@ setMethod("gsva", signature(expr="ExpressionSet", gset.idx.list="GeneSetCollecti |
138 | 135 |
} |
139 | 136 |
|
140 | 137 |
eSco <- .gsva(exprs(expr), mapped.gset.idx.list, method, kcdf, rnaseq, abs.ranking, |
141 |
- parallel.sz, parallel.type, mx.diff, tau, kernel, ssgsea.norm, |
|
142 |
- verbose, BPPARAM) |
|
138 |
+ parallel.sz, mx.diff, tau, kernel, ssgsea.norm, verbose, BPPARAM) |
|
143 | 139 |
|
144 | 140 |
eScoEset <- new("ExpressionSet", exprs=eSco, phenoData=phenoData(expr), |
145 | 141 |
experimentData=experimentData(expr), annotation="") |
... | ... |
@@ -157,7 +153,6 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="GeneSetCollection"), |
157 | 153 |
min.sz=1, |
158 | 154 |
max.sz=Inf, |
159 | 155 |
parallel.sz=1L, |
160 |
- parallel.type="SOCK", |
|
161 | 156 |
mx.diff=TRUE, |
162 | 157 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
163 | 158 |
ssgsea.norm=TRUE, |
... | ... |
@@ -218,7 +213,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="GeneSetCollection"), |
218 | 213 |
} |
219 | 214 |
|
220 | 215 |
rval <- .gsva(expr, mapped.gset.idx.list, method, kcdf, rnaseq, abs.ranking, |
221 |
- parallel.sz, parallel.type, mx.diff, tau, kernel, ssgsea.norm, |
|
216 |
+ parallel.sz, mx.diff, tau, kernel, ssgsea.norm, |
|
222 | 217 |
verbose, BPPARAM) |
223 | 218 |
|
224 | 219 |
rval |
... | ... |
@@ -232,7 +227,6 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
232 | 227 |
min.sz=1, |
233 | 228 |
max.sz=Inf, |
234 | 229 |
parallel.sz=1L, |
235 |
- parallel.type="SOCK", |
|
236 | 230 |
mx.diff=TRUE, |
237 | 231 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
238 | 232 |
ssgsea.norm=TRUE, |
... | ... |
@@ -281,8 +275,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
281 | 275 |
} |
282 | 276 |
|
283 | 277 |
rval <- .gsva(expr, mapped.gset.idx.list, method, kcdf, rnaseq, abs.ranking, |
284 |
- parallel.sz, parallel.type, mx.diff, tau, kernel, ssgsea.norm, |
|
285 |
- verbose, BPPARAM) |
|
278 |
+ parallel.sz, mx.diff, tau, kernel, ssgsea.norm, verbose, BPPARAM) |
|
286 | 279 |
|
287 | 280 |
rval |
288 | 281 |
}) |
... | ... |
@@ -293,7 +286,6 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
293 | 286 |
rnaseq=FALSE, |
294 | 287 |
abs.ranking=FALSE, |
295 | 288 |
parallel.sz=1L, |
296 |
- parallel.type="SOCK", |
|
297 | 289 |
mx.diff=TRUE, |
298 | 290 |
tau=1, |
299 | 291 |
kernel=TRUE, |
... | ... |
@@ -328,8 +320,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
328 | 320 |
cat("Estimating ssGSEA scores for", length(gset.idx.list),"gene sets.\n") |
329 | 321 |
|
330 | 322 |
return(ssgsea(expr, gset.idx.list, alpha=tau, parallel.sz=parallel.sz, |
331 |
- parallel.type=parallel.type, normalization=ssgsea.norm, |
|
332 |
- verbose=verbose, BPPARAM=BPPARAM)) |
|
323 |
+ normalization=ssgsea.norm, verbose=verbose, BPPARAM=BPPARAM)) |
|
333 | 324 |
} |
334 | 325 |
|
335 | 326 |
if (method == "zscore") { |
... | ... |
@@ -339,8 +330,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
339 | 330 |
if(verbose) |
340 | 331 |
cat("Estimating combined z-scores for", length(gset.idx.list), "gene sets.\n") |
341 | 332 |
|
342 |
- return(zscore(expr, gset.idx.list, parallel.sz, parallel.type, |
|
343 |
- verbose, BPPARAM=BPPARAM)) |
|
333 |
+ return(zscore(expr, gset.idx.list, parallel.sz, verbose, BPPARAM=BPPARAM)) |
|
344 | 334 |
} |
345 | 335 |
|
346 | 336 |
if (method == "plage") { |
... | ... |
@@ -350,8 +340,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
350 | 340 |
if(verbose) |
351 | 341 |
cat("Estimating PLAGE scores for", length(gset.idx.list),"gene sets.\n") |
352 | 342 |
|
353 |
- return(plage(expr, gset.idx.list, parallel.sz, parallel.type, |
|
354 |
- verbose, BPPARAM=BPPARAM)) |
|
343 |
+ return(plage(expr, gset.idx.list, parallel.sz, verbose, BPPARAM=BPPARAM)) |
|
355 | 344 |
} |
356 | 345 |
|
357 | 346 |
if(verbose) |
... | ... |
@@ -367,7 +356,7 @@ setMethod("gsva", signature(expr="matrix", gset.idx.list="list"), |
367 | 356 |
|
368 | 357 |
es.obs <- compute.geneset.es(expr, gset.idx.list, 1:n.samples, |
369 | 358 |
rnaseq=rnaseq, abs.ranking=abs.ranking, |
370 |
- parallel.sz=parallel.sz, parallel.type=parallel.type, |
|
359 |
+ parallel.sz=parallel.sz, |
|
371 | 360 |
mx.diff=mx.diff, tau=tau, kernel=kernel, |
372 | 361 |
verbose=verbose, BPPARAM=BPPARAM) |
373 | 362 |
|
... | ... |
@@ -407,7 +396,7 @@ compute.gene.density <- function(expr, sample.idxs, rnaseq=FALSE, kernel=TRUE){ |
407 | 396 |
} |
408 | 397 |
|
409 | 398 |
compute.geneset.es <- function(expr, gset.idx.list, sample.idxs, rnaseq=FALSE, |
410 |
- abs.ranking, parallel.sz=1L, parallel.type="SOCK", |
|
399 |
+ abs.ranking, parallel.sz=1L, |
|
411 | 400 |
mx.diff=TRUE, tau=1, kernel=TRUE, |
412 | 401 |
verbose=TRUE, BPPARAM=SerialParam(progressbar=verbose)) { |
413 | 402 |
num_genes <- nrow(expr) |
... | ... |
@@ -558,8 +547,8 @@ setCores <- function(nCores, parallel.sz) { |
558 | 547 |
} |
559 | 548 |
|
560 | 549 |
ssgsea <- function(X, geneSets, alpha=0.25, parallel.sz, |
561 |
- parallel.type, normalization=TRUE, |
|
562 |
- verbose=TRUE, BPPARAM=SerialParam(progressbar=verbose)) { |
|
550 |
+ normalization=TRUE, verbose=TRUE, |
|
551 |
+ BPPARAM=SerialParam(progressbar=verbose)) { |
|
563 | 552 |
|
564 | 553 |
p <- nrow(X) |
565 | 554 |
n <- ncol(X) |
... | ... |
@@ -628,8 +617,8 @@ ssgsea <- function(X, geneSets, alpha=0.25, parallel.sz, |
628 | 617 |
|
629 | 618 |
combinez <- function(gSetIdx, j, Z) sum(Z[gSetIdx, j]) / sqrt(length(gSetIdx)) |
630 | 619 |
|
631 |
-zscore <- function(X, geneSets, parallel.sz, parallel.type, |
|
632 |
- verbose=TRUE, BPPARAM=SerialParam(progressbar=verbose)) { |
|
620 |
+zscore <- function(X, geneSets, parallel.sz, verbose=TRUE, |
|
621 |
+ BPPARAM=SerialParam(progressbar=verbose)) { |
|
633 | 622 |
|
634 | 623 |
p <- nrow(X) |
635 | 624 |
n <- ncol(X) |
... | ... |
@@ -691,8 +680,8 @@ rightsingularsvdvectorgset <- function(gSetIdx, Z) { |
691 | 680 |
s$v[, 1] |
692 | 681 |
} |
693 | 682 |
|
694 |
-plage <- function(X, geneSets, parallel.sz, parallel.type, |
|
695 |
- verbose=TRUE, BPPARAM=SerialParam(progressbar=verbose)) { |
|
683 |
+plage <- function(X, geneSets, parallel.sz, verbose=TRUE, |
|
684 |
+ BPPARAM=SerialParam(progressbar=verbose)) { |
|
696 | 685 |
|
697 | 686 |
p <- nrow(X) |
698 | 687 |
n <- ncol(X) |
... | ... |
@@ -21,7 +21,6 @@ Estimates GSVA enrichment scores. |
21 | 21 |
min.sz=1, |
22 | 22 |
max.sz=Inf, |
23 | 23 |
parallel.sz=1L, |
24 |
- parallel.type="SOCK", |
|
25 | 24 |
mx.diff=TRUE, |
26 | 25 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
27 | 26 |
ssgsea.norm=TRUE, |
... | ... |
@@ -34,7 +33,6 @@ Estimates GSVA enrichment scores. |
34 | 33 |
min.sz=1, |
35 | 34 |
max.sz=Inf, |
36 | 35 |
parallel.sz=1L, |
37 |
- parallel.type="SOCK", |
|
38 | 36 |
mx.diff=TRUE, |
39 | 37 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
40 | 38 |
ssgsea.norm=TRUE, |
... | ... |
@@ -47,7 +45,6 @@ Estimates GSVA enrichment scores. |
47 | 45 |
min.sz=1, |
48 | 46 |
max.sz=Inf, |
49 | 47 |
parallel.sz=1L, |
50 |
- parallel.type="SOCK", |
|
51 | 48 |
mx.diff=TRUE, |
52 | 49 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
53 | 50 |
ssgsea.norm=TRUE, |
... | ... |
@@ -60,7 +57,6 @@ Estimates GSVA enrichment scores. |
60 | 57 |
min.sz=1, |
61 | 58 |
max.sz=Inf, |
62 | 59 |
parallel.sz=1L, |
63 |
- parallel.type="SOCK", |
|
64 | 60 |
mx.diff=TRUE, |
65 | 61 |
tau=switch(method, gsva=1, ssgsea=0.25, NA), |
66 | 62 |
ssgsea.norm=TRUE, |
... | ... |
@@ -106,7 +102,6 @@ Estimates GSVA enrichment scores. |
106 | 102 |
\item{parallel.sz}{Number of threads of execution to use when doing the calculations in parallel. |
107 | 103 |
The argument \code{BPPARAM} allows one to set the parallel back-end and fine |
108 | 104 |
tune its configuration.} |
109 |
- \item{parallel.type}{Type of cluster architecture when using \code{snow}.} |
|
110 | 105 |
\item{mx.diff}{Offers two approaches to calculate the enrichment statistic (ES) |
111 | 106 |
from the KS random walk statistic. \code{mx.diff=FALSE}: ES is calculated as |
112 | 107 |
the maximum distance of the random walk from 0. \code{mx.diff=TRUE} (default): ES |