-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
38 changed files
with
1,277 additions
and
1,167 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.Rproj.user | ||
.Rhistory | ||
.RData | ||
vignettes/figure | ||
*.Rproj | ||
vignettes/R_cache | ||
vignettes/R_figure | ||
old_scripts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,39 @@ | ||
Package: scone | ||
Version: 0.0.1 | ||
Version: 0.0.3 | ||
Title: Single Cell Overview of Normalized Expression data | ||
Description: SCONE. | ||
Description: scone is a package to compare and rank the performance of different normalization schemes in real single-cell RNA-seq datasets. | ||
Authors@R: c(person("Michael", "Cole", email = "mbeloc@gmail.com", | ||
role = c("aut", "cre", "cph")), | ||
person("Davide", "Risso", email = "risso.davide@gmail.com", | ||
role = c("aut"))) | ||
Author: Michael Cole [aut, cre, cph] and Davide Risso [aut] | ||
Maintainer: Michael Cole <mbeloc@gmail.com> | ||
Imports: BiocParallel, DESeq, EDASeq, MASS, RUVSeq, aroma.light, class, | ||
diptest, edgeR, fpc, gplots, limma, matrixStats, mixtools, scde | ||
Date: 02-06-2016 | ||
Date: 2016-02-14 | ||
License: Artistic-2.0 | ||
Depends: | ||
R (>= 3.1) | ||
Imports: | ||
BiocParallel, | ||
clusterCells, | ||
DESeq, | ||
EDASeq, | ||
MASS, | ||
RUVSeq, | ||
aroma.light, | ||
class, | ||
diptest, | ||
edgeR, | ||
fpc, | ||
gplots, | ||
limma, | ||
matrixStats, | ||
mixtools, | ||
scde | ||
Suggests: | ||
knitr, | ||
rmarkdown, | ||
testthat | ||
VignetteBuilder: knitr | ||
LazyLoad: yes | ||
BugReports: https://github.com/epurdom/clusterExperiment/issues | ||
RoxygenNote: 5.0.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
## When porting the package to S4, we can make this a biplot method | ||
|
||
#' Another implementation of the biplot function | ||
#' | ||
#' Function to plot a biplot with no point labels and with points color-coded | ||
#' according to a certain quantitative variable, for instance the rank of the | ||
#' normalization performance or the expression of a certain gene. | ||
#' | ||
#' This function implements the biplot only for \code{\link[stats]{prcomp}} | ||
#' objects. Eventually, we will turn this into an S4 method. | ||
#' | ||
#' @param x the result of a call to \code{\link[stats]{prcomp}}. | ||
#' @param y the rank value that should be used to color the points. | ||
#' @param choices which principal components to plot. Only 2D plots are | ||
#' possible for now. Default to first two PCs. | ||
#' @param expand numeric value used to adjust the spread of the arrows relative | ||
#' to the points. | ||
#' @param ... passed to plot. | ||
#' | ||
#' @importFrom grDevices colorRampPalette | ||
#' @export | ||
#' | ||
#' @examples | ||
#' mat <- matrix(rnorm(1000), ncol=10) | ||
#' colnames(mat) <- paste("X", 1:ncol(mat), sep="") | ||
#' | ||
#' pc <- prcomp(mat) | ||
#' | ||
#' biplot_colored(pc, rank(pc$x[,1])) | ||
#' | ||
biplot_colored <- function(x, y, choices=1:2, expand=1, ...) { | ||
|
||
lam <- x$sdev[choices] | ||
n <- NROW(x$x) | ||
lam <- lam * sqrt(n) | ||
|
||
xx <- t(t(x$x[, choices])/lam) | ||
yy <- t(t(x$rotation[, choices]) * lam) | ||
|
||
ratio <- max(range(yy)/range(xx))/expand | ||
|
||
cols <- rev(colorRampPalette(c("black","navyblue","mediumblue","dodgerblue3","aquamarine4","green4","yellowgreen","yellow"))(length(y)))[y] | ||
plot(xx, pch=19, col=cols, ...) | ||
|
||
labs <- rownames(yy) | ||
|
||
text(yy/ratio, labels=labs, col=2) | ||
arrows(0, 0, yy[, 1] * 0.8/ratio, yy[, 2] * 0.8/ratio, col = 2, length = 0.1) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
#' Positive and negative control genes | ||
#' | ||
#' Sets of positive and negative control genes, useful for input in | ||
#' \code{\link{scone}}. | ||
#' | ||
#' These gene sets can be used as negative or positive controls, either for RUV | ||
#' normalization or for evaluation and ranking of the normalization strategies. | ||
#' | ||
#' @details The datasets are in the form of \code{data.frame}, with at least one | ||
#' column containing the gene symbols and optionally a second column | ||
#' containing additional information (such as cortical layer or cell cycle | ||
#' phase). | ||
#' | ||
#' @details Note that the gene symbols follow the mouse conventions (i.e., | ||
#' capitalized) or the human conventions (i.e, all upper-case), based on the | ||
#' original pubblication. One can use the \code{\link[base]{toupper}}, | ||
#' \code{\link[base]{tolower}}, and \code{\link[tools]{toTitleCase}} functions | ||
#' to convert the symbols. | ||
#' | ||
#' @details The genes in \code{cortical_markers} are from Figure 3 of Molyneaux | ||
#' et al. (2007). The genes in \code{housekeeping} are from Eisenberg and | ||
#' Levanon (2003) and in \code{housekeeping_revised} are from Eisenberg and | ||
#' Levanon (2013). The genes in \code{cellcycle_genes} are adapted from | ||
#' Kowalczyk et al. (2015). | ||
#' | ||
#' @references Molyneaux, B.J., Arlotta, P., Menezes, J.R. and Macklis, J.D.. | ||
#' Neuronal subtype specification in the cerebral cortex. Nature Reviews | ||
#' Neuroscience, 2007, 8(6):427-437. | ||
#' @references Eisenberg E, Levanon EY. Human housekeeping genes are compact. | ||
#' Trends in Genetics, 2003, 19(7):362-5. | ||
#' @references Eisenberg E, Levanon EY. Human housekeeping genes, revisited. | ||
#' Trends in Genetics, 2013, 29(10):569-74. | ||
#' @references Kowalczyk, M.S., Tirosh, I., Heckl, D., Rao, T.N., Dixit, A., | ||
#' Haas, B.J., Schneider, R.K., Wagers, A.J., Ebert, B.L. and Regev, A. | ||
#' Single-cell RNA-seq reveals changes in cell cycle and differentiation | ||
#' programs upon aging of hematopoietic stem cells. Genome research, 2015. | ||
#' | ||
#' @name control_genes | ||
#' | ||
#' @docType data | ||
#' @aliases cortical_markers housekeeping housekeeping_revised cellcycle_genes | ||
#' | ||
#' @examples | ||
#' data(housekeeping) | ||
#' data(housekeeping_revised) | ||
#' data(cellcycle_genes) | ||
#' data(cortical_markers) | ||
NULL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.