Browse code

Moved example data to singlecellexperiment and misc_functions. This version of the toolkit won't work very well because I removed scater but some of the files haven't been converted yet. Follow the progress spreadsheet and test each function individually before merging to master

David Jenkins authored on 03/08/2017 22:34:14
Showing 27 changed files

... ...
@@ -1,11 +1,12 @@
1 1
 Package: singleCellTK
2 2
 Type: Package
3 3
 Title: Interactive Analysis of Single Cell RNA-Seq Data
4
-Version: 0.1.8
4
+Version: 0.1.999
5 5
 Author: David Jenkins
6 6
 Maintainer: David Jenkins <[email protected]>
7 7
 Depends:
8
-    R (>= 3.2)
8
+    R (>= 3.2),
9
+    SingleCellExperiment
9 10
 Description: Run common single cell analysis directly through your browser
10 11
     including differential expression, downsampling analysis, and clustering.
11 12
 License: MIT + file LICENSE
... ...
@@ -38,11 +39,10 @@ Imports:
38 39
     rsvd,
39 40
     Rtsne,
40 41
     S4Vectors,
41
-    scater,
42 42
     shiny,
43 43
     shinyjs
44 44
 RoxygenNote: 6.0.1
45
-Suggests: 
45
+Suggests:
46 46
     Rsubread,
47 47
     knitr,
48 48
     rmarkdown
... ...
@@ -5,7 +5,7 @@ export(MAST)
5 5
 export(MASTregression)
6 6
 export(MASTviolin)
7 7
 export(alignSingleCellData)
8
-export(createSCESet)
8
+export(createSCE)
9 9
 export(differentialPower)
10 10
 export(filterSCData)
11 11
 export(getBiomarker)
... ...
@@ -22,6 +22,7 @@ export(plot_d3DiffEx)
22 22
 export(runDimRed)
23 23
 export(runPCA)
24 24
 export(scDiffEx)
25
+export(scDiffEx_anova)
25 26
 export(scDiffEx_deseq)
26 27
 export(scDiffEx_deseq2)
27 28
 export(scDiffEx_limma)
... ...
@@ -1,4 +1,5 @@
1
-#' Example Single Cell RNA-Seq data in SCESet Object, GSE60361 subest
1
+#' Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE60361
2
+#' subest
2 3
 #'
3 4
 #' A subset of 30 samples from a single cell RNA-Seq experiment from Zeisel, et
4 5
 #' al. Science 2015. The data was produced from cells from the mouse
... ...
@@ -6,93 +7,67 @@
6 7
 #' identified as oligodendrocytes and 15 of the cell were identified as
7 8
 #' microglia.
8 9
 #'
9
-#' @name GSE60361_subset
10
+#' @name GSE60361_subset_sce
10 11
 #' @docType data
11
-#' @format List of two data frames, with counts and annotations. Use them as
12
-#' input to createSCESet()
12
+#' @format SingleCellExperiment
13 13
 #' @source DOI: 10.1126/science.aaa1934
14 14
 #' @keywords datasets
15 15
 #' @examples
16
-#' library(scater)
17
-#' data("GSE60361_subset")
18
-#' GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
19
-#'                                 annotfile = GSE60361_subset$annot,
20
-#'                                 inputdataframes = TRUE)
21
-"GSE60361_subset"
16
+#' data("GSE60361_subset_sce")
17
+"GSE60361_subset_sce"
22 18
 
23
-#' Example Single Cell RNA-Seq data in SCESet Object, GSE73121
19
+#' Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE73121
24 20
 #'
25 21
 #' 117 Single-cell transcriptome profiling for metastatic renal cell carcinoma
26 22
 #' patient-derived cells
27 23
 #'
28
-#' @name GSE73121
24
+#' @name GSE73121_sce
29 25
 #' @docType data
30
-#' @format List of two data frames, with counts and annotations. Use them as
31
-#' input to createSCESet()
26
+#' @format SingleCellExperiment
32 27
 #' @source DOI: 10.1186/s13059-016-0945-9
33 28
 #' @keywords datasets
34 29
 #' @examples
35
-#' library(scater)
36
-#' data("GSE73121")
37
-#' GSE73121_SCESet <- createSCESet(countfile = GSE73121$counts,
38
-#'                                 annotfile = GSE73121$annot,
39
-#'                                 inputdataframes = TRUE)
40
-"GSE73121"
30
+#' data("GSE73121_sce")
31
+"GSE73121_sce"
41 32
 
42
-#' Example Single Cell RNA-Seq data in SCESet Object, GSE66507
33
+#' Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE66507
43 34
 #'
44 35
 #' 30 Single-cells from embryonic stem cells separated into three different
45 36
 #' tissue types.
46 37
 #'
47
-#' @name GSE66507
38
+#' @name GSE66507_sce
48 39
 #' @docType data
49
-#' @format List of two data frames, with counts and annotations. Use them as
50
-#' input to createSCESet()
40
+#' @format SingleCellExperiment
51 41
 #' @source DOI: 10.1242/dev.123547
52 42
 #' @keywords datasets
53 43
 #' @examples
54
-#' library(scater)
55
-#' data("GSE66507")
56
-#' GSE66507_SCESet <- createSCESet(countfile = GSE66507$counts,
57
-#'                                 annotfile = GSE66507$annot,
58
-#'                                 inputdataframes = TRUE)
59
-"GSE66507"
44
+#' data("GSE66507_sce")
45
+"GSE66507_sce"
60 46
 
61
-#' Example Single Cell RNA-Seq data in SCESet Object, GSE36552
47
+#' Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE36552
62 48
 #'
63 49
 #' 124 Single-cell transcriptome profiling from embryonic stem cells derived
64 50
 #' from donated human pre-implatation embryos.
65 51
 #'
66
-#' @name GSE36552
52
+#' @name GSE36552_sce
67 53
 #' @docType data
68
-#' @format List of two data frames, with counts and annotations. Use them as
69
-#' input to createSCESet()
54
+#' @format SingleCellExperiment
70 55
 #' @source DOI: 10.1038/nsmb.2660
71 56
 #' @keywords datasets
72 57
 #' @examples
73
-#' library(scater)
74
-#' data("GSE36552")
75
-#' GSE36552_SCESet <- createSCESet(countfile = GSE36552$counts,
76
-#'                                 annotfile = GSE36552$annot,
77
-#'                                 inputdataframes = TRUE)
78
-"GSE36552"
58
+#' data("GSE36552_sce")
59
+"GSE36552_sce"
79 60
 
80 61
 #' Example Single Cell RNA-Seq MAITS data from MAST package
81 62
 #'
82 63
 #' 96 Single-cell transcriptome profiling from Mucosal Associated Invariant T
83 64
 #' cells (MAITs), measured on the Fluidigm C1.
84 65
 #'
85
-#' @name maits_SCESet
66
+#' @name maits_sce
86 67
 #' @docType data
87
-#' @format List of three data frames, with counts, features and annotations.
88
-#' Use them as input to createSCESet()
68
+#' @format SingleCellExperiment
89 69
 #' @source DOI: 10.1186/s13059-015-0844-5
90 70
 #' @keywords datasets
91 71
 #' @examples
92
-#' library(scater)
93
-#' data("maits_SCESet")
94
-#' maits_SCESet <- createSCESet(countfile = maits_SCESet$counts,
95
-#'                              annotfile = maits_SCESet$annot,
96
-#'                              featurefile = maits_SCESet$features,
97
-#'                              inputdataframes = TRUE)
98
-"maits_SCESet"
72
+#' data("maits_sce")
73
+"maits_sce"
... ...
@@ -1,8 +1,8 @@
1
-#' Summarize SCESet
1
+#' Summarize SingleCellExperiment
2 2
 #'
3
-#' Creates a table of summary metrics from an input SCESet.
3
+#' Creates a table of summary metrics from an input SingleCellExperiment.
4 4
 #'
5
-#' @param indata Input SCESet
5
+#' @param indata Input SingleCellExperiment
6 6
 #'
7 7
 #' @return A data.frame object of summary metrics.
8 8
 #' @export summarizeTable
... ...
@@ -15,16 +15,16 @@ summarizeTable <- function(indata){
15 15
                                "Genes with no expression across all samples"),
16 16
                     "Value" = c(ncol(indata),
17 17
                               nrow(indata),
18
-                              as.integer(mean(apply(scater::counts(indata), 2, function(x) sum(x)))),
19
-                              as.integer(mean(apply(scater::counts(indata), 2, function(x) sum(x > 0)))),
20
-                              sum(apply(scater::counts(indata), 2, function(x) sum(as.numeric(x) == 0)) < 1700),
21
-                              sum(rowSums(scater::counts(indata)) == 0))))
18
+                              as.integer(mean(apply(assay(indata, "counts"), 2, function(x) sum(x)))),
19
+                              as.integer(mean(apply(assay(indata, "counts"), 2, function(x) sum(x > 0)))),
20
+                              sum(apply(assay(indata, "counts"), 2, function(x) sum(as.numeric(x) == 0)) < 1700),
21
+                              sum(rowSums(assay(indata, "counts")) == 0))))
22 22
 }
23 23
 
24
-#' Create a SCESet object
24
+#' Create a SingleCellExperiment object
25 25
 #'
26
-#' From a file of counts and a file of annotation information, create a SCESet
27
-#' object.
26
+#' From a file of counts and a file of annotation information, create a
27
+#' SingleCellExperiment object.
28 28
 #'
29 29
 #' @param countfile The path to a text file that contains a header row of sample
30 30
 #' names, and rows of raw counts per gene for those samples.
... ...
@@ -37,16 +37,15 @@ summarizeTable <- function(indata){
37 37
 #' @param inputdataframes If TRUE, countfile and annotfile are read as data
38 38
 #' frames instead of file paths. The default is FALSE.
39 39
 #'
40
-#' @return a SCESet object
41
-#' @export createSCESet
40
+#' @return a SingleCellExperiment object
41
+#' @export createSCE
42 42
 #' @examples
43
-#' library(scater)
44
-#' data("GSE60361_subset")
45
-#' GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
46
-#'                                 annotfile = GSE60361_subset$annot,
47
-#'                                 inputdataframes = TRUE)
48
-createSCESet <- function(countfile=NULL, annotfile=NULL, featurefile=NULL,
49
-                         inputdataframes=FALSE){
43
+#' \dontrun{
44
+#' GSE60361_sce <- createSCE(countfile = "/path/to/input_counts.txt",
45
+#'                           annotfile = "/path/to/input_annots.txt")
46
+#'}
47
+createSCE <- function(countfile=NULL, annotfile=NULL, featurefile=NULL,
48
+                      inputdataframes=FALSE){
50 49
   if (is.null(countfile)){
51 50
     stop("You must supply a count file.")
52 51
   }
... ...
@@ -66,15 +65,16 @@ createSCESet <- function(countfile=NULL, annotfile=NULL, featurefile=NULL,
66 65
   if (is.null(annotfile)){
67 66
     annotin <- data.frame(row.names = colnames(countsin))
68 67
     annotin$Sample <- rownames(annotin)
68
+    annotin <- DataFrame(annotin)
69 69
   }
70 70
   if (is.null(featurefile)){
71 71
     featurein <- data.frame(Gene = rownames(countsin))
72 72
     rownames(featurein) <- featurein$Gene
73
+    featurein <- DataFrame(featurein)
73 74
   }
74
-  pd <- methods::new("AnnotatedDataFrame", data = annotin)
75
-  fd <- methods::new("AnnotatedDataFrame", data = featurein)
76
-  return(scater::newSCESet(countData = countsin, phenoData = pd,
77
-                           featureData = fd))
75
+  return(SummarizedExperiment(assays=list(counts=as.matrix(countsin)),
76
+                              colData=annotin,
77
+                              rowData=featurein))
78 78
 }
79 79
 
80 80
 #' Filter Genes and Samples from a Single Cell Object
... ...
@@ -92,22 +92,18 @@ createSCESet <- function(countfile=NULL, annotfile=NULL, featurefile=NULL,
92 92
 #' @export filterSCData
93 93
 #'
94 94
 #' @examples
95
-#' library(scater)
96
-#' data("GSE60361_subset")
97
-#' GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
98
-#'                                 annotfile = GSE60361_subset$annot,
99
-#'                                 inputdataframes = TRUE)
100
-#' GSE60361_SCESet_filtered <- filterSCData(GSE60361_SCESet,
101
-#'                                          deletesamples="X1772063061_G11")
95
+#' data("GSE60361_subset_sce")
96
+#' GSE60361_subset_sce <- filterSCData(GSE60361_subset_sce,
97
+#'                                     deletesamples="X1772063061_G11")
102 98
 filterSCData <- function(insceset, deletesamples=NULL, remove_noexpress=TRUE,
103 99
                          remove_bottom=0.5, minimum_detect_genes=1700){
104 100
   insceset <- insceset[, !(colnames(insceset) %in% deletesamples)]
105 101
   if (remove_noexpress){
106
-    insceset <- insceset[rowSums(counts(insceset)) != 0, ]
102
+    insceset <- insceset[rowSums(assay(insceset, "counts")) != 0, ]
107 103
   }
108 104
   nkeeprows <- ceiling((1 - remove_bottom) * as.numeric(nrow(insceset)))
109
-  tokeeprow <- order(rowSums(counts(insceset)), decreasing = TRUE)[1:nkeeprows]
110
-  tokeepcol <- apply(counts(insceset), 2, function(x) sum(as.numeric(x) == 0)) >= minimum_detect_genes
105
+  tokeeprow <- order(rowSums(assay(insceset, "counts")), decreasing = TRUE)[1:nkeeprows]
106
+  tokeepcol <- apply(assay(insceset, "counts"), 2, function(x) sum(as.numeric(x) == 0)) >= minimum_detect_genes
111 107
   insceset <- insceset[tokeeprow, tokeepcol]
112 108
   return(insceset)
113 109
 }
114 110
deleted file mode 100644
... ...
@@ -1,26 +0,0 @@
1
-% Generated by roxygen2: do not edit by hand
2
-% Please edit documentation in R/data.R
3
-\docType{data}
4
-\name{GSE36552}
5
-\alias{GSE36552}
6
-\title{Example Single Cell RNA-Seq data in SCESet Object, GSE36552}
7
-\format{List of two data frames, with counts and annotations. Use them as
8
-input to createSCESet()}
9
-\source{
10
-DOI: 10.1038/nsmb.2660
11
-}
12
-\usage{
13
-GSE36552
14
-}
15
-\description{
16
-124 Single-cell transcriptome profiling from embryonic stem cells derived
17
-from donated human pre-implatation embryos.
18
-}
19
-\examples{
20
-library(scater)
21
-data("GSE36552")
22
-GSE36552_SCESet <- createSCESet(countfile = GSE36552$counts,
23
-                                annotfile = GSE36552$annot,
24
-                                inputdataframes = TRUE)
25
-}
26
-\keyword{datasets}
27 0
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+% Generated by roxygen2: do not edit by hand
2
+% Please edit documentation in R/data.R
3
+\docType{data}
4
+\name{GSE36552_sce}
5
+\alias{GSE36552_sce}
6
+\title{Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE36552}
7
+\format{SingleCellExperiment}
8
+\source{
9
+DOI: 10.1038/nsmb.2660
10
+}
11
+\usage{
12
+GSE36552_sce
13
+}
14
+\description{
15
+124 Single-cell transcriptome profiling from embryonic stem cells derived
16
+from donated human pre-implatation embryos.
17
+}
18
+\examples{
19
+data("GSE36552_sce")
20
+}
21
+\keyword{datasets}
0 22
similarity index 51%
1 23
rename from man/GSE60361_subset.Rd
2 24
rename to man/GSE60361_subset_sce.Rd
... ...
@@ -1,16 +1,16 @@
1 1
 % Generated by roxygen2: do not edit by hand
2 2
 % Please edit documentation in R/data.R
3 3
 \docType{data}
4
-\name{GSE60361_subset}
5
-\alias{GSE60361_subset}
6
-\title{Example Single Cell RNA-Seq data in SCESet Object, GSE60361 subest}
7
-\format{List of two data frames, with counts and annotations. Use them as
8
-input to createSCESet()}
4
+\name{GSE60361_subset_sce}
5
+\alias{GSE60361_subset_sce}
6
+\title{Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE60361
7
+subest}
8
+\format{SingleCellExperiment}
9 9
 \source{
10 10
 DOI: 10.1126/science.aaa1934
11 11
 }
12 12
 \usage{
13
-GSE60361_subset
13
+GSE60361_subset_sce
14 14
 }
15 15
 \description{
16 16
 A subset of 30 samples from a single cell RNA-Seq experiment from Zeisel, et
... ...
@@ -20,10 +20,6 @@ identified as oligodendrocytes and 15 of the cell were identified as
20 20
 microglia.
21 21
 }
22 22
 \examples{
23
-library(scater)
24
-data("GSE60361_subset")
25
-GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
26
-                                annotfile = GSE60361_subset$annot,
27
-                                inputdataframes = TRUE)
23
+data("GSE60361_subset_sce")
28 24
 }
29 25
 \keyword{datasets}
30 26
deleted file mode 100644
... ...
@@ -1,26 +0,0 @@
1
-% Generated by roxygen2: do not edit by hand
2
-% Please edit documentation in R/data.R
3
-\docType{data}
4
-\name{GSE66507}
5
-\alias{GSE66507}
6
-\title{Example Single Cell RNA-Seq data in SCESet Object, GSE66507}
7
-\format{List of two data frames, with counts and annotations. Use them as
8
-input to createSCESet()}
9
-\source{
10
-DOI: 10.1242/dev.123547
11
-}
12
-\usage{
13
-GSE66507
14
-}
15
-\description{
16
-30 Single-cells from embryonic stem cells separated into three different
17
-tissue types.
18
-}
19
-\examples{
20
-library(scater)
21
-data("GSE66507")
22
-GSE66507_SCESet <- createSCESet(countfile = GSE66507$counts,
23
-                                annotfile = GSE66507$annot,
24
-                                inputdataframes = TRUE)
25
-}
26
-\keyword{datasets}
27 0
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+% Generated by roxygen2: do not edit by hand
2
+% Please edit documentation in R/data.R
3
+\docType{data}
4
+\name{GSE66507_sce}
5
+\alias{GSE66507_sce}
6
+\title{Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE66507}
7
+\format{SingleCellExperiment}
8
+\source{
9
+DOI: 10.1242/dev.123547
10
+}
11
+\usage{
12
+GSE66507_sce
13
+}
14
+\description{
15
+30 Single-cells from embryonic stem cells separated into three different
16
+tissue types.
17
+}
18
+\examples{
19
+data("GSE66507_sce")
20
+}
21
+\keyword{datasets}
0 22
deleted file mode 100644
... ...
@@ -1,26 +0,0 @@
1
-% Generated by roxygen2: do not edit by hand
2
-% Please edit documentation in R/data.R
3
-\docType{data}
4
-\name{GSE73121}
5
-\alias{GSE73121}
6
-\title{Example Single Cell RNA-Seq data in SCESet Object, GSE73121}
7
-\format{List of two data frames, with counts and annotations. Use them as
8
-input to createSCESet()}
9
-\source{
10
-DOI: 10.1186/s13059-016-0945-9
11
-}
12
-\usage{
13
-GSE73121
14
-}
15
-\description{
16
-117 Single-cell transcriptome profiling for metastatic renal cell carcinoma
17
-patient-derived cells
18
-}
19
-\examples{
20
-library(scater)
21
-data("GSE73121")
22
-GSE73121_SCESet <- createSCESet(countfile = GSE73121$counts,
23
-                                annotfile = GSE73121$annot,
24
-                                inputdataframes = TRUE)
25
-}
26
-\keyword{datasets}
27 0
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+% Generated by roxygen2: do not edit by hand
2
+% Please edit documentation in R/data.R
3
+\docType{data}
4
+\name{GSE73121_sce}
5
+\alias{GSE73121_sce}
6
+\title{Example Single Cell RNA-Seq data in SingleCellExperiment Object, GSE73121}
7
+\format{SingleCellExperiment}
8
+\source{
9
+DOI: 10.1186/s13059-016-0945-9
10
+}
11
+\usage{
12
+GSE73121_sce
13
+}
14
+\description{
15
+117 Single-cell transcriptome profiling for metastatic renal cell carcinoma
16
+patient-derived cells
17
+}
18
+\examples{
19
+data("GSE73121_sce")
20
+}
21
+\keyword{datasets}
0 22
similarity index 65%
1 23
rename from man/createSCESet.Rd
2 24
rename to man/createSCE.Rd
... ...
@@ -1,10 +1,10 @@
1 1
 % Generated by roxygen2: do not edit by hand
2 2
 % Please edit documentation in R/misc_functions.R
3
-\name{createSCESet}
4
-\alias{createSCESet}
5
-\title{Create a SCESet object}
3
+\name{createSCE}
4
+\alias{createSCE}
5
+\title{Create a SingleCellExperiment object}
6 6
 \usage{
7
-createSCESet(countfile = NULL, annotfile = NULL, featurefile = NULL,
7
+createSCE(countfile = NULL, annotfile = NULL, featurefile = NULL,
8 8
   inputdataframes = FALSE)
9 9
 }
10 10
 \arguments{
... ...
@@ -20,20 +20,18 @@ annotation information for each gene in the count matrix. This file should
20 20
 have the same genes in the same order as countfile. This is optional.}
21 21
 
22 22
 \item{inputdataframes}{If TRUE, countfile and annotfile are read as data
23
-frames instead of file paths. The default is FALSE.
24
-instead of}
23
+frames instead of file paths. The default is FALSE.}
25 24
 }
26 25
 \value{
27
-a SCESet object
26
+a SingleCellExperiment object
28 27
 }
29 28
 \description{
30
-From a file of counts and a file of annotation information, create a SCESet
31
-object.
29
+From a file of counts and a file of annotation information, create a
30
+SingleCellExperiment object.
32 31
 }
33 32
 \examples{
34
-library(scater)
35
-data("GSE60361_subset")
36
-GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
37
-                                annotfile = GSE60361_subset$annot,
38
-                                inputdataframes = TRUE)
33
+\dontrun{
34
+GSE60361_sce <- createSCE(countfile = "/path/to/input_counts.txt",
35
+                          annotfile = "/path/to/input_annots.txt")
36
+}
39 37
 }
... ...
@@ -28,11 +28,7 @@ The filtered single cell object.
28 28
 Filter Genes and Samples from a Single Cell Object
29 29
 }
30 30
 \examples{
31
-library(scater)
32
-data("GSE60361_subset")
33
-GSE60361_SCESet <- createSCESet(countfile = GSE60361_subset$counts,
34
-                                annotfile = GSE60361_subset$annot,
35
-                                inputdataframes = TRUE)
36
-GSE60361_SCESet_filtered <- filterSCData(GSE60361_SCESet,
37
-                                         deletesamples="X1772063061_G11")
31
+data("GSE60361_subset_sce")
32
+GSE60361_subset_sce <- filterSCData(GSE60361_subset_sce,
33
+                                    deletesamples="X1772063061_G11")
38 34
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/getBiomarker.R
3 3
 \name{getBiomarker}
4 4
 \alias{getBiomarker}
5
-\title{get Biomarker
6
-  
7
-Use this function to get expression or binary data of gene list}
5
+\title{get Biomarker}
8 6
 \usage{
9 7
 getBiomarker(count_data, gene, binary = "Binary")
10 8
 }
... ...
@@ -19,7 +17,5 @@ getBiomarker(count_data, gene, binary = "Binary")
19 17
 A PCA plot
20 18
 }
21 19
 \description{
22
-get Biomarker
23
-  
24 20
 Use this function to get expression or binary data of gene list
25 21
 }
... ...
@@ -2,11 +2,7 @@
2 2
 % Please edit documentation in R/getPCA.R
3 3
 \name{getPCA}
4 4
 \alias{getPCA}
5
-\title{Get PCA components for a feature counts table
6
-  
7
-Selects the 500 most variable genes in the feature count, performs
8
-PCA based on them and outputs the principal components in a data frame
9
-and their variances as percentVar attribute}
5
+\title{Get PCA components for a feature counts table}
10 6
 \usage{
11 7
 getPCA(count_data)
12 8
 }
... ...
@@ -17,8 +13,6 @@ getPCA(count_data)
17 13
 A reduced dimension object
18 14
 }
19 15
 \description{
20
-Get PCA components for a feature counts table
21
-  
22 16
 Selects the 500 most variable genes in the feature count, performs
23 17
 PCA based on them and outputs the principal components in a data frame
24 18
 and their variances as percentVar attribute
... ...
@@ -2,11 +2,7 @@
2 2
 % Please edit documentation in R/getTSNE.R
3 3
 \name{getTSNE}
4 4
 \alias{getTSNE}
5
-\title{Get t-SNE components for a feature counts table
6
-  
7
-Selects the 500 most variable genes in the feature count, performs
8
-t-SNE based on them and outputs the principal components in a data frame
9
-and their variances as percentVar attribute}
5
+\title{Get t-SNE components for a feature counts table}
10 6
 \usage{
11 7
 getTSNE(count_data)
12 8
 }
... ...
@@ -17,8 +13,6 @@ getTSNE(count_data)
17 13
 A reduced dimension object
18 14
 }
19 15
 \description{
20
-Get t-SNE components for a feature counts table
21
-  
22 16
 Selects the 500 most variable genes in the feature count, performs
23 17
 t-SNE based on them and outputs the principal components in a data frame
24 18
 and their variances as percentVar attribute
25 19
deleted file mode 100644
... ...
@@ -1,27 +0,0 @@
1
-% Generated by roxygen2: do not edit by hand
2
-% Please edit documentation in R/data.R
3
-\docType{data}
4
-\name{maits_SCESet}
5
-\alias{maits_SCESet}
6
-\title{Example Single Cell RNA-Seq MAITS data from MAST package}
7
-\format{List of three data frames, with counts, features and annotations.
8
-Use them as input to createSCESet()}
9
-\source{
10
-DOI: 10.1186/s13059-015-0844-5
11
-}
12
-\usage{
13
-maits_SCESet
14
-}
15
-\description{
16
-96 Single-cell transcriptome profiling from Mucosal Associated Invariant T
17
-cells (MAITs), measured on the Fluidigm C1.
18
-}
19
-\examples{
20
-library(scater)
21
-data("maits_SCESet")
22
-maits_SCESet <- createSCESet(countfile = maits_SCESet$counts,
23
-                             annotfile = maits_SCESet$annot,
24
-                             featurefile = maits_SCESet$features,
25
-                             inputdataframes = TRUE)
26
-}
27
-\keyword{datasets}
28 0
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+% Generated by roxygen2: do not edit by hand
2
+% Please edit documentation in R/data.R
3
+\docType{data}
4
+\name{maits_sce}
5
+\alias{maits_sce}
6
+\title{Example Single Cell RNA-Seq MAITS data from MAST package}
7
+\format{SingleCellExperiment}
8
+\source{
9
+DOI: 10.1186/s13059-015-0844-5
10
+}
11
+\usage{
12
+maits_sce
13
+}
14
+\description{
15
+96 Single-cell transcriptome profiling from Mucosal Associated Invariant T
16
+cells (MAITs), measured on the Fluidigm C1.
17
+}
18
+\examples{
19
+data("maits_sce")
20
+}
21
+\keyword{datasets}
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/plotBiomarker.R
3 3
 \name{plotBiomarker}
4 4
 \alias{plotBiomarker}
5
-\title{get Biomarker
6
-  
7
-Use this function to get expression or binary data of gene list}
5
+\title{get Biomarker}
8 6
 \usage{
9 7
 plotBiomarker(count_data, gene, binary = "Binary", visual = "PCA",
10 8
   shape = "No Shape", axis_df = NULL, x = "PC1", y = "PC2")
... ...
@@ -30,7 +28,5 @@ plotBiomarker(count_data, gene, binary = "Binary", visual = "PCA",
30 28
 A Biomarker plot
31 29
 }
32 30
 \description{
33
-get Biomarker
34
-  
35 31
 Use this function to get expression or binary data of gene list
36 32
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/plotDimRed.R
3 3
 \name{plotDimRed}
4 4
 \alias{plotDimRed}
5
-\title{Plot PCA or tSNE
6
-  
7
-Use this function to plot PCA or tSNE results}
5
+\title{Plot PCA or tSNE}
8 6
 \usage{
9 7
 plotDimRed(method, vals_method, count_data, colorClusters, pc1, pc2)
10 8
 }
... ...
@@ -25,7 +23,5 @@ plotDimRed(method, vals_method, count_data, colorClusters, pc1, pc2)
25 23
 A reduced dimension object
26 24
 }
27 25
 \description{
28
-Plot PCA or tSNE
29
-  
30 26
 Use this function to plot PCA or tSNE results
31 27
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/plotPCA.R
3 3
 \name{plotPCA}
4 4
 \alias{plotPCA}
5
-\title{Plot PCA
6
-  
7
-Use this function to plot PCA or tSNE results}
5
+\title{Plot PCA}
8 6
 \usage{
9 7
 plotPCA(count_data, pca_df = NULL, colorBy = NULL, shape = NULL,
10 8
   pcX = "PC1", pcY = "PC2")
... ...
@@ -26,7 +24,5 @@ plotPCA(count_data, pca_df = NULL, colorBy = NULL, shape = NULL,
26 24
 A PCA plot
27 25
 }
28 26
 \description{
29
-Plot PCA
30
-  
31 27
 Use this function to plot PCA or tSNE results
32 28
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/plotTSNE.R
3 3
 \name{plotTSNE}
4 4
 \alias{plotTSNE}
5
-\title{Plot TSNE
6
-  
7
-Use this function to plot PCA or tSNE results}
5
+\title{Plot TSNE}
8 6
 \usage{
9 7
 plotTSNE(count_data, tsne_df = NULL, colorBy = NULL, shape = NULL)
10 8
 }
... ...
@@ -21,7 +19,5 @@ plotTSNE(count_data, tsne_df = NULL, colorBy = NULL, shape = NULL)
21 19
 A TSNE plot
22 20
 }
23 21
 \description{
24
-Plot TSNE
25
-  
26 22
 Use this function to plot PCA or tSNE results
27 23
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/runDimRed.R
3 3
 \name{runDimRed}
4 4
 \alias{runDimRed}
5
-\title{Run PCA or tSNE
6
-  
7
-Use this function to run limma differential expression and load an interactive D3 heatmap}
5
+\title{Run PCA or tSNE}
8 6
 \usage{
9 7
 runDimRed(method, count_data, colorClusters, pc1, pc2)
10 8
 }
... ...
@@ -23,7 +21,5 @@ runDimRed(method, count_data, colorClusters, pc1, pc2)
23 21
 A reduced dimension object
24 22
 }
25 23
 \description{
26
-Run PCA or tSNE
27
-  
28 24
 Use this function to run limma differential expression and load an interactive D3 heatmap
29 25
 }
... ...
@@ -2,9 +2,7 @@
2 2
 % Please edit documentation in R/runPCA.R
3 3
 \name{runPCA}
4 4
 \alias{runPCA}
5
-\title{Run multiple PCA approach
6
-  
7
-Use this function to run Principle component Analysis using different approach and load plot}
5
+\title{Run multiple PCA approach}
8 6
 \usage{
9 7
 runPCA(plot.type, method, countm, annotm, featurem, involving.variables,
10 8
   additional.variables, colorClusters)
... ...
@@ -30,7 +28,6 @@ runPCA(plot.type, method, countm, annotm, featurem, involving.variables,
30 28
 A reduced dimension object
31 29
 }
32 30
 \description{
33
-Run multiple PCA approach
34
-  
35
-Use this function to run Principle component Analysis using different approach and load plot
31
+Use this function to run Principle component Analysis using different
32
+approach and load plot
36 33
 }
37 34
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+% Generated by roxygen2: do not edit by hand
2
+% Please edit documentation in R/scDiffEx.R
3
+\name{scDiffEx_anova}
4
+\alias{scDiffEx_anova}
5
+\title{Perform ANOVA analysis}
6
+\usage{
7
+scDiffEx_anova(inSCESet, condition)
8
+}
9
+\arguments{
10
+\item{inSCESet}{Input SCESet object. Required}
11
+
12
+\item{condition}{The name of the condition to use for differential
13
+expression. Must be a name of a column from pData that contains two labels.
14
+Required}
15
+}
16
+\value{
17
+A data frame of gene names and adjusted p-values
18
+}
19
+\description{
20
+Returns a data frame of gene names and adjusted p-values
21
+}
... ...
@@ -14,7 +14,7 @@ singlecell_SVM(train_set, train_label, test_set, var, tune_para = FALSE,
14 14
 
15 15
 \item{test_set}{The test dataset (cells x features)}
16 16
 
17
-\item{var}{feature names used for predicting cell quality ##}
17
+\item{var}{feature names used for predicting cell quality}
18 18
 
19 19
 \item{tune_para}{boolean values determining if doing the parameter tuning}
20 20
 
... ...
@@ -2,16 +2,16 @@
2 2
 % Please edit documentation in R/misc_functions.R
3 3
 \name{summarizeTable}
4 4
 \alias{summarizeTable}
5
-\title{Summarize SCESet}
5
+\title{Summarize SingleCellExperiment}
6 6
 \usage{
7 7
 summarizeTable(indata)
8 8
 }
9 9
 \arguments{
10
-\item{indata}{Input SCESet}
10
+\item{indata}{Input SingleCellExperiment}
11 11
 }
12 12
 \value{
13 13
 A data.frame object of summary metrics.
14 14
 }
15 15
 \description{
16
-Creates a table of summary metrics from an input SCESet.
16
+Creates a table of summary metrics from an input SingleCellExperiment.
17 17
 }