Skip to content

Commit

Permalink
configured vignettee
Browse files Browse the repository at this point in the history
  • Loading branch information
debsin committed Aug 29, 2019
1 parent b690693 commit a3663c9
Show file tree
Hide file tree
Showing 14 changed files with 18 additions and 1,725 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Package: dropClust
rmPackage: dropClust
Type: Package
Title: Single Cell Transcriptome Analysis
Version: 2.1.0
Expand Down
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ importFrom(SingleCellExperiment,counts)
importFrom(SingleCellExperiment,normcounts)
importFrom(SingleCellExperiment,reducedDim)
importFrom(SingleCellExperiment,reducedDimNames)
importFrom(SingleCellExperiment,reducedDims)
importFrom(SingleCellExperiment,rowData)
importFrom(ggplot2,aes)
importFrom(ggplot2,aes_string)
Expand Down
2 changes: 1 addition & 1 deletion R/emeddings.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#' \code{reducedDim()} containter to store the reduced dimension components
#' with the name from the argument \code{embedding}.
#' @importFrom methods is
#' @importFrom SingleCellExperiment colData reducedDim<- normcounts
#' @importFrom SingleCellExperiment colData reducedDim reducedDim<- normcounts
#' @export
#' @examples
#' library(SingleCellExperiment)
Expand Down
15 changes: 8 additions & 7 deletions R/plots.R
Original file line number Diff line number Diff line change
Expand Up @@ -135,19 +135,20 @@ getColors<-function(n){
# --------------------------------------------------
#' Plotting cells
#' @description Scatter plot of cells in two dimensions
#' @param data data frame containing 3 columns:\cr
#' \enumerate{
#' \item \code{Y1}: numeric values of each point in x-axis.
#' \item \code{Y2}: numeric values of each point in y-axis.
#' \item \code{color}: factor, cluster identifiers for each point.
#' }
#' @param object A SingleCellExperiment object after performing clustering and plot embedding.
#' @param filename (optional) specify file path to save plot in pdf format.
#' @param title character, specify plot title.
#' @return grob object
#' @export
#' @importFrom SingleCellExperiment reducedDim reducedDims reducedDim<-
#' @importFrom ggplot2 ggplot geom_point aes scale_colour_manual theme_classic theme ggtitle annotate guides guide_legend ylab xlab aes_string
#' @importFrom methods is
ScatterPlot<-function(data,filename=NA, title){
ScatterPlot<-function(object,filename=NA, title){

embedding = tail(names(reducedDims(object)),1)

data = data.frame("Y1" = reducedDim(object,embedding)[,1], Y2 = reducedDim(object, embedding)[,2], color = object$ClusterIDs)


temp = stats::complete.cases(data)
plot_proj_df = data[temp, ]
Expand Down
56 changes: 0 additions & 56 deletions doc/batchCorrection.R

This file was deleted.

68 changes: 0 additions & 68 deletions doc/batchCorrection.Rmd

This file was deleted.

Loading

0 comments on commit a3663c9

Please sign in to comment.