Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
sirplus
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
BioCellGen-public
sirplus
Commits
7d79daa4
Commit
7d79daa4
authored
7 years ago
by
Luke Zappia
Browse files
Options
Downloads
Patches
Plain Diff
Add diffSCESets to vignette
parent
d71fbd1b
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
R/compare.R
+5
-6
5 additions, 6 deletions
R/compare.R
man/diffSCESets.Rd
+3
-3
3 additions, 3 deletions
man/diffSCESets.Rd
vignettes/splatter.Rmd
+21
-0
21 additions, 0 deletions
vignettes/splatter.Rmd
with
29 additions
and
9 deletions
R/compare.R
+
5
−
6
View file @
7d79daa4
...
...
@@ -219,12 +219,11 @@ compareSCESets <- function(sces) {
#' @examples
#' sim1 <- splatSimulate(nGenes = 1000, groupCells = 20)
#' sim2 <- simpleSimulate(nGenes = 1000, nCells = 20)
#' comparison <- compareSCESets(list(Splat = sim1, Simple = sim2))
#' names(comparison)
#' names(comparison$Plots)
#' @importFrom ggplot2 ggplot aes_string geom_point geom_smooth geom_boxplot
#' geom_violin scale_y_continuous scale_y_log10 scale_x_log10 xlab ylab ggtitle
#' theme_minimal
#' difference <- diffSCESets(list(Splat = sim1, Simple = sim2), ref = "Simple")
#' names(difference)
#' names(difference$Plots)
#' @importFrom ggplot2 ggplot aes_string geom_point geom_boxplot xlab ylab
#' ggtitle theme_minimal
#' @importFrom scater cpm<-
#' @export
diffSCESets
<-
function
(
sces
,
ref
)
{
...
...
This diff is collapsed.
Click to expand it.
man/diffSCESets.Rd
+
3
−
3
View file @
7d79daa4
...
...
@@ -70,7 +70,7 @@ using \code{\link[ggplot2]{ggplot}}.
\examples{
sim1 <- splatSimulate(nGenes = 1000, groupCells = 20)
sim2 <- simpleSimulate(nGenes = 1000, nCells = 20)
comparison <- compare
SCESets(list(Splat = sim1, Simple = sim2))
names(
comparison
)
names(
comparison
$Plots)
difference <- diff
SCESets(list(Splat = sim1, Simple = sim2)
, ref = "Simple"
)
names(
difference
)
names(
difference
$Plots)
}
This diff is collapsed.
Click to expand it.
vignettes/splatter.Rmd
+
21
−
0
View file @
7d79daa4
...
...
@@ -452,6 +452,27 @@ ggplot(comparison$PhenoData,
geom_point()
```
## Comparing differences
Sometimes instead of visually comparing datasets it may be more interesting to
look at the differences between them. We can do this using the `diffSCESets`
function. Similar to `compareSCESets` this function takes a list of `SCESet`
objects but now we also specify one to be a reference. A series of similar plots
are returned but instead of showing the overall distributions they demonstrate
differences from the reference.
```{r difference}
difference <- diffSCESets(list(Splat = sim1, Simple = sim2), ref = "Simple")
difference$Plots$Means
```
We also get a series of Quantile-Quantile plot that can be used to compare
distributions.
```{r difference-qq}
difference$QQPlots$Means
```
# Session information {-}
```{r sessionInfo}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment