-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME.Rmd
97 lines (73 loc) · 2.96 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "70%"
)
```
# concordexR
<!-- badges: start -->
[![codecov](https://codecov.io/gh/pachterlab/concordexR/branch/main/graph/badge.svg?token=FSASJPR4T5)](https://codecov.io/gh/pachterlab/concordexR)
[![Bioc devel status](http://www.bioconductor.org/shields/build/devel/bioc/concordexR.svg)](https://bioconductor.org/checkResults/devel/bioc-LATEST/concordexR)
<!-- badges: end -->
The goal of concordexR is to identify spatial homogeneous regions (SHRs) as
defined in the recent manuscript, ["Identification of spatial homogenous regions in tissues with concordex"](https://doi.org/10.1101/2023.06.28.546949). Briefly, SHRs are are
domains that are homogeneous with respect to cell type composition. `concordex`
relies on the the k-nearest-neighbor (kNN) graph to representing similarities
between cells and uses common clustering algorithms to identify SHRs.
## Installation
Versions of the `concordexR` package that do not enable clustering spatial data
into spatial homogeneous regions (SHRs) are available for Bioconductor versions
3.17-19. The most recent version of the package is slated to be released on
Bioconductor version 3.20.
```{r}
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install(version="3.20")
BiocManager::install("concordexR")
```
## Example
This is a basic example using concordex:
```{r load libraries}
library(SFEData)
library(Voyager)
library(scran)
library(bluster)
library(concordexR)
```
```{r}
sfe <- McKellarMuscleData("small")
clusters <- quickCluster(sfe, min.size=2, d=15)
```
```{r example}
nbc <- calculateConcordex(
sfe,
clusters,
n_neighbors=10,
BLUSPARAM=KmeansParam(2)
)
colData(sfe)[["shr"]] <- attr(nbc, "shrs")
```
```{r plot-shr}
plotSpatialFeature(sfe, features="shr")
```
## Citation
If you'd like to use the `concordexR` package in your research, please cite our
recent bioRxiv preprint
> Jackson, K.; Booeshaghi, A. S.; Gálvez-Merchán, Á.; Moses, L.; Chari, T.; Pachter, L. Quantitative assessment of single-cell RNA-seq clustering with CONCORDEX. bioRxiv (Cold Spring Harbor Laboratory) 2023. https://doi.org/10.1101/2023.06.28.546949.
> @article {Jackson2023.06.28.546949,
author = {Jackson, Kayla C. and Booeshaghi, A. Sina and G{\'a}lvez-Merch{\'a}n, {\'A}ngel and Moses, Lambda and Chari, Tara and Kim, Alexandra and Pachter, Lior},
title = {Identification of spatial homogeneous regions in tissues with concordex},
year = {2024},
doi = {10.1101/2023.06.28.546949},
publisher = {Cold Spring Harbor Laboratory},
URL = {https://www.biorxiv.org/content/early/2024/07/18/2023.06.28.546949},
journal = {bioRxiv}
}
## Maintainer
[Kayla Jackson](https://github.com/kayla-jackson)