SCORPIUS

Linear trajectory inference for single-cell RNA-seq

https://github.com/rcannood/scorpius

Science Score: 36.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
    Found 3 DOI reference(s) in README
  • Academic publication links
    Links to: biorxiv.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (17.8%) to scientific vocabulary

Keywords from Contributors

bioinformatics single-cell bioconductor scrna-seq transcriptome
Last synced: 10 months ago · JSON representation

Repository

Linear trajectory inference for single-cell RNA-seq

Basic Info
Statistics
  • Stars: 61
  • Watchers: 5
  • Forks: 16
  • Open Issues: 15
  • Releases: 4
Created over 10 years ago · Last pushed about 2 years ago
Metadata Files
Readme Changelog

README.Rmd

---
output:
  github_document:
    html_preview: false
editor_options: 
  chunk_output_type: console
bibliography: library.bib
---

```{r setup1, include=FALSE}
knitr::opts_chunk$set(fig.path = "man/figures/README_", warning = FALSE, message = FALSE, error = FALSE, echo = TRUE)

submission_to_cran <- TRUE
library(tidyverse)
```


# SCORPIUS


[![R-CMD-check](https://github.com/rcannood/SCORPIUS/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/rcannood/SCORPIUS/actions/workflows/R-CMD-check.yaml)
[![CRAN_Status_Badge](https://www.r-pkg.org/badges/version/SCORPIUS)](https://cran.r-project.org/package=SCORPIUS)
[![Codecov test coverage](https://codecov.io/gh/rcannood/SCORPIUS/branch/master/graph/badge.svg)](https://app.codecov.io/gh/rcannood/SCORPIUS?branch=master)


SCORPIUS an unsupervised approach for inferring linear developmental chronologies from single-cell
RNA sequencing data. In comparison to similar approaches, it has three main advantages:

* **It accurately reconstructs linear dynamic processes.** 
  The performance was evaluated using a quantitative evaluation pipeline and
  ten single-cell RNA sequencing datasets. 
  
* **It automatically identifies marker genes, speeding up knowledge discovery.**
  
* **It is fully unsupervised.** Prior knowledge of the relevant marker genes or 
  cellular states of individual cells is not required.
  
News: 

* See `news(package = "SCORPIUS")` for a full list of changes to the package.

* Our preprint is on [bioRxiv](https://biorxiv.org/content/early/2016/10/07/079509)
  [@Cannoodt2016].

* Check out our [review](https://dx.doi.org/10.1038/s41587-019-0071-9) on Trajectory Inference methods
  [@Saelens2019].
  
## Installing SCORPIUS

You can install:

* the latest released version from CRAN with

    ```R
    install.packages("SCORPIUS")
    ```

* the latest development version from GitHub with

    ```R
    devtools::install_github("rcannood/SCORPIUS", build_vignettes = TRUE)
    ```

If you encounter a bug, please file a minimal reproducible example on the [issues](https://github.com/rcannood/SCORPIUS/issues) page. 

## Learning SCORPIUS

To get started, read the introductory example below, or read one of the vignettes containing more elaborate examples:

```{r vignettes, results='asis', echo=FALSE}
walk(
  list.files("vignettes", pattern = "*.Rmd"),
  function(file) {
    title <- 
      read_lines(paste0("vignettes/", file)) %>% 
      keep(~grepl("^title: ", .)) %>% 
      gsub("title: \"(.*)\"", "\\1", .)
    vignette_name <- gsub("\\.Rmd", "", file)
    cat(
      "* ", title, ":  \n",
      "`vignette(\"", vignette_name, "\", package=\"SCORPIUS\")`\n", 
      sep = ""
    )
  }
)
```

## Introductory example

```{r, echo=F}
set.seed(1)
```

This section describes the main workflow of SCORPIUS without going in depth in the R code. For a more detailed explanation, see the vignettes listed below.

To start using SCORPIUS, simply write:
```{r libraries, message=FALSE}
library(SCORPIUS)
```


The `ginhoux` dataset [@Schlitzer2015] contains 248 dendritic cell progenitors in one of three cellular cellular states: MDP, CDP or PreDC. Note that this is a reduced version of the dataset, for packaging reasons. See ?ginhoux for more info.
```{r load_ginhoux}
data(ginhoux)
expression <- ginhoux$expression
group_name <- ginhoux$sample_info$group_name
```


With the following code, SCORPIUS reduces the dimensionality of the dataset and provides a visual overview of the dataset. 
In this plot, cells that are similar in terms of expression values will be placed closer together than cells with dissimilar expression values.

```{r reduce_dimensionality}
space <- reduce_dimensionality(expression, "spearman")
draw_trajectory_plot(space, group_name, contour = TRUE)
```


To infer and visualise a trajectory through these cells, run:
```{r infer_trajectory}
traj <- infer_trajectory(space)
draw_trajectory_plot(space, group_name, traj$path, contour = TRUE)
```

To identify candidate marker genes, run:
```{r find_tafs, message=F, warning=F}
# warning: setting num_permutations to 10 requires a long time (~30min) to run!
# set it to 0 and define a manual cutoff for the genes (e.g. top 200) for a much shorter execution time.
gimp <- gene_importances(
  expression, 
  traj$time, 
  num_permutations = 10, 
  num_threads = 8, 
  ntree = 10000,
  ntree_perm = 1000
) 
```

To select the most important genes and scale its expression, run:
```{r calculate_pvalue, message=F, warning=F}
gimp$qvalue <- p.adjust(gimp$pvalue, "BH", length(gimp$pvalue))
gene_sel <- gimp$gene[gimp$qvalue < .05]
expr_sel <- scale_quantile(expression[,gene_sel])
```


```{r echo=F}
# reverse the trajectory. This does not change the results in any way,
# other than the heatmap being ordered more logically.
# traj <- reverse_trajectory(traj)
```

To visualise the expression of the selected genes, use the `draw_trajectory_heatmap` function.
```{r visualise_tafs, fig.keep='first'}
draw_trajectory_heatmap(expr_sel, traj$time, group_name)
```

Finally, these genes can also be grouped into modules as follows: 
```{r moduled_tafs, fig.keep='first'}
modules <- extract_modules(scale_quantile(expr_sel), traj$time, verbose = F)
draw_trajectory_heatmap(expr_sel, traj$time, group_name, modules)
```

## References

Owner

  • Name: Robrecht Cannoodt
  • Login: rcannood
  • Kind: user
  • Location: Ghent, Belgium
  • Company: Data Intuitive

Data science engineer at Data Intuitive.

GitHub Events

Total
  • Issues event: 1
  • Watch event: 2
Last Year
  • Issues event: 1
  • Watch event: 2

Committers

Last synced: 10 months ago

All Time
  • Total Commits: 345
  • Total Committers: 3
  • Avg Commits per committer: 115.0
  • Development Distribution Score (DDS): 0.006
Past Year
  • Commits: 0
  • Committers: 0
  • Avg Commits per committer: 0.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Robrecht Cannoodt r****d@g****m 343
Wouter Saelens w****s@g****m 1
Darío Hereñú m****a@g****m 1

Issues and Pull Requests

Last synced: 11 months ago

All Time
  • Total issues: 37
  • Total pull requests: 9
  • Average time to close issues: 6 months
  • Average time to close pull requests: about 2 hours
  • Total issue authors: 24
  • Total pull request authors: 3
  • Average comments per issue: 2.35
  • Average comments per pull request: 0.44
  • Merged pull requests: 8
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 2
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 2
  • Pull request authors: 0
  • Average comments per issue: 0.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • lucygarner (10)
  • rcannood (2)
  • alikhuseynov (2)
  • zouter (2)
  • violehtone (2)
  • saketkc (1)
  • sherriying (1)
  • siddharthst (1)
  • anjanbharadwaj (1)
  • JiahuaQu (1)
  • Safwat08 (1)
  • Han-zh210 (1)
  • zhouqihy (1)
  • chitopia (1)
  • giovanegt (1)
Pull Request Authors
  • rcannood (7)
  • asif7adil (1)
  • kant (1)
Top Labels
Issue Labels
enhancement (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • cran 269 last-month
  • Total docker downloads: 21,661
  • Total dependent packages: 0
  • Total dependent repositories: 1
  • Total versions: 10
  • Total maintainers: 1
cran.r-project.org: SCORPIUS

Inferring Developmental Chronologies from Single-Cell RNA Sequencing Data

  • Versions: 10
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 269 Last month
  • Docker Downloads: 21,661
Rankings
Docker downloads count: 0.6%
Forks count: 4.6%
Stargazers count: 6.7%
Average: 15.8%
Dependent repos count: 24.0%
Dependent packages count: 28.8%
Downloads: 30.4%
Maintainers (1)
Last synced: 10 months ago

Dependencies

DESCRIPTION cran
  • R >= 3.5.0 depends
  • MASS * imports
  • Matrix * imports
  • RANN * imports
  • RColorBrewer * imports
  • TSP * imports
  • dplyr * imports
  • dynutils >= 1.0.3 imports
  • dynwrap * imports
  • ggplot2 >= 2.0 imports
  • grDevices * imports
  • lmds * imports
  • mclust * imports
  • methods * imports
  • pbapply * imports
  • pheatmap * imports
  • princurve >= 2.1.4 imports
  • purrr * imports
  • ranger * imports
  • reshape2 * imports
  • stats * imports
  • tidyr * imports
  • R.rsp * suggests
  • covr * suggests
  • knitr * suggests
  • rmarkdown * suggests
  • testthat >= 2.1.0 suggests
.github/workflows/R-CMD-check.yaml actions
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • r-lib/actions/check-r-package v2 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/pkgdown.yaml actions
  • JamesIves/github-pages-deploy-action v4.4.1 composite
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/test-coverage.yaml actions
  • actions/checkout v3 composite
  • actions/upload-artifact v3 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite