├── .DS_Store
├── .Rbuildignore
├── .gitignore
├── DESCRIPTION
├── LICENSE
├── NAMESPACE
├── NEWS.md
├── R
├── .DS_Store
├── deconvolution.R
├── extensions.R
├── interaction.R
├── utilities.R
└── visualization.R
├── README.Rmd
├── README.md
├── SpaCET.Rproj
├── _pkgdown.yml
├── docs
├── .DS_Store
├── 404.html
├── LICENSE-text.html
├── articles
│ ├── GeneSetScore.html
│ ├── hiresST_CRC.html
│ ├── img
│ │ ├── CAF-M2.png
│ │ ├── CCC.png
│ │ ├── GS1.png
│ │ ├── GS2.png
│ │ ├── GS3.png
│ │ ├── LRNetworkScore.png
│ │ ├── PDAC_CCC.png
│ │ ├── PDAC_expr.png
│ │ ├── PDAC_prop.png
│ │ ├── QC.png
│ │ ├── cancerCellState.png
│ │ ├── cancerDictionary.png
│ │ ├── cancerInterface1.png
│ │ ├── cancerInterface2.png
│ │ ├── cancerInterface3.png
│ │ ├── slideseq_anno.png
│ │ ├── slideseq_prop.png
│ │ ├── visualizeDeconvolution.png
│ │ ├── visualizeDeconvolution2.png
│ │ └── visualizeDeconvolution3.png
│ ├── index.html
│ ├── oldST_PDAC.html
│ └── visium_BC.html
├── authors.html
├── deps
│ ├── bootstrap-5.1.0
│ │ ├── bootstrap.bundle.min.js
│ │ ├── bootstrap.bundle.min.js.map
│ │ └── bootstrap.min.css
│ ├── data-deps.txt
│ └── jquery-3.6.0
│ │ ├── jquery-3.6.0.js
│ │ ├── jquery-3.6.0.min.js
│ │ └── jquery-3.6.0.min.map
├── index.html
├── link.svg
├── news
│ └── index.html
├── pkgdown.js
├── pkgdown.yml
├── reference
│ ├── SpaCET-class.html
│ ├── SpaCET.CCI.LRNetworkScore.html
│ ├── SpaCET.CCI.cellTypePair.html
│ ├── SpaCET.CCI.colocalization.html
│ ├── SpaCET.GeneSetScore.html
│ ├── SpaCET.combine.interface.html
│ ├── SpaCET.deconvolution.html
│ ├── SpaCET.deconvolution.malignant.html
│ ├── SpaCET.deconvolution.matched.scRNAseq.html
│ ├── SpaCET.distance.to.interface.html
│ ├── SpaCET.identify.interface.html
│ ├── SpaCET.quality.control.html
│ ├── SpaCET.visualize.cellTypePair.html
│ ├── SpaCET.visualize.colocalization.html
│ ├── SpaCET.visualize.spatialFeature.html
│ ├── addTo.Seurat.html
│ ├── convert.Seurat.html
│ ├── create.SpaCET.object.10X.html
│ ├── create.SpaCET.object.html
│ ├── figures
│ │ ├── sticker.png
│ │ └── workflow.png
│ ├── index.html
│ ├── read.gmt.html
│ └── write.gmt.html
├── search.json
└── sitemap.xml
├── inst
├── .DS_Store
└── extdata
│ ├── .DS_Store
│ ├── GeneSets
│ ├── CancerCellState.gmt
│ ├── Hallmark.gmt
│ └── TLS.gmt
│ ├── LR.txt
│ ├── Ref_Normal_LIHC.rda
│ ├── Visium_BC
│ ├── .DS_Store
│ ├── filtered_feature_bc_matrix.h5
│ ├── filtered_feature_bc_matrix
│ │ ├── .DS_Store
│ │ ├── barcodes.tsv.gz
│ │ ├── features.tsv.gz
│ │ └── matrix.mtx.gz
│ └── spatial
│ │ ├── scalefactors_json.json
│ │ ├── tissue_lowres_image.png
│ │ └── tissue_positions_list.csv
│ ├── cancerDictionary.rda
│ ├── combRef_0.5.rda
│ ├── hiresST_CRC
│ ├── .DS_Store
│ ├── colors_vector.rda
│ ├── counts.rda
│ └── spotCoordinates.rda
│ └── oldST_PDAC
│ ├── .DS_Store
│ ├── sc_PDAC.rda
│ └── st_PDAC.rda
├── man
├── .DS_Store
├── SpaCET-class.Rd
├── SpaCET.CCI.LRNetworkScore.Rd
├── SpaCET.CCI.cellTypePair.Rd
├── SpaCET.CCI.colocalization.Rd
├── SpaCET.GeneSetScore.Rd
├── SpaCET.combine.interface.Rd
├── SpaCET.deconvolution.Rd
├── SpaCET.deconvolution.malignant.Rd
├── SpaCET.deconvolution.malignant.customized.scRNAseq.Rd
├── SpaCET.deconvolution.matched.scRNAseq.Rd
├── SpaCET.distance.to.interface.Rd
├── SpaCET.identify.interface.Rd
├── SpaCET.quality.control.Rd
├── SpaCET.visualize.cellTypePair.Rd
├── SpaCET.visualize.colocalization.Rd
├── SpaCET.visualize.spatialFeature.Rd
├── addTo.Seurat.Rd
├── convert.Seurat.Rd
├── create.SpaCET.object.10X.Rd
├── create.SpaCET.object.Rd
├── figures
│ ├── .DS_Store
│ ├── sticker.png
│ └── workflow.png
├── read.gmt.Rd
└── write.gmt.Rd
└── vignettes
├── .DS_Store
├── GeneSetScore.Rmd
├── hiresST_CRC.Rmd
├── img
├── .DS_Store
├── CAF-M2.png
├── CCC.png
├── GS1.png
├── GS2.png
├── GS3.png
├── LRNetworkScore.png
├── PDAC_CCC.png
├── PDAC_expr.png
├── PDAC_prop.png
├── QC.png
├── cancerCellState.png
├── cancerDictionary.png
├── cancerInterface1.png
├── cancerInterface2.png
├── cancerInterface3.png
├── slideseq_anno.png
├── slideseq_prop.png
├── visualizeDeconvolution.png
├── visualizeDeconvolution2.png
└── visualizeDeconvolution3.png
├── oldST_PDAC.Rmd
└── visium_BC.Rmd
/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/.DS_Store
--------------------------------------------------------------------------------
/.Rbuildignore:
--------------------------------------------------------------------------------
1 | ^.*\.Rproj$
2 | ^\.Rproj\.user$
3 | ^README.Rmd
4 | ^docs
5 | ^_pkgdown\.yml$
6 | ^docs$
7 | ^pkgdown$
8 | ^\.travis\.yml$
9 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .Rproj.user
2 | .Rhistory
3 | .RData
4 | .Ruserdata
5 | docs
6 |
--------------------------------------------------------------------------------
/DESCRIPTION:
--------------------------------------------------------------------------------
1 | Package: SpaCET
2 | Version: 1.3.0
3 | Title: Spatial Cellular Estimator for Tumors
4 | Description: Estimation of cell lineages in tumors from spatial transcriptomics data.
5 | Authors@R: c(person(given = "Beibei",family = "Ru", role = c("aut", "cre"), email = "beibei.ru@nih.gov"),person(given = "Peng",family = "Jiang", role = c("aut"), email = "peng.jiang@nih.gov"))
6 | License: file LICENSE
7 | URL: https://github.com/data2intelligence/SpaCET
8 | BugReports: https://github.com/data2intelligence/SpaCET/issues
9 | Encoding: UTF-8
10 | RoxygenNote: 7.2.3
11 | Depends:
12 | R (>= 3.5.0)
13 | Imports:
14 | Matrix,
15 | jsonlite,
16 | ggplot2,
17 | reshape2,
18 | patchwork,
19 | png,
20 | shiny,
21 | plotly,
22 | DT,
23 | factoextra,
24 | NbClust,
25 | cluster,
26 | parallel,
27 | pbmcapply,
28 | psych,
29 | BiRewire,
30 | limma,
31 | arrow,
32 | UCell,
33 | MUDAN
34 | biocViews:
35 | UCell
36 | remotes:
37 | JEFworks/MUDAN
38 |
--------------------------------------------------------------------------------
/NAMESPACE:
--------------------------------------------------------------------------------
1 | # Generated by roxygen2: do not edit by hand
2 |
3 | export(SpaCET.CCI.LRNetworkScore)
4 | export(SpaCET.CCI.cellTypePair)
5 | export(SpaCET.CCI.colocalization)
6 | export(SpaCET.GeneSetScore)
7 | export(SpaCET.combine.interface)
8 | export(SpaCET.deconvolution)
9 | export(SpaCET.deconvolution.malignant)
10 | export(SpaCET.deconvolution.malignant.customized.scRNAseq)
11 | export(SpaCET.deconvolution.matched.scRNAseq)
12 | export(SpaCET.distance.to.interface)
13 | export(SpaCET.identify.interface)
14 | export(SpaCET.quality.control)
15 | export(SpaCET.visualize.cellTypePair)
16 | export(SpaCET.visualize.colocalization)
17 | export(SpaCET.visualize.spatialFeature)
18 | export(addTo.Seurat)
19 | export(convert.Seurat)
20 | export(create.SpaCET.object)
21 | export(create.SpaCET.object.10X)
22 | export(read.gmt)
23 | export(write.gmt)
24 | importFrom(Matrix,readMM)
25 | importFrom(jsonlite,fromJSON)
26 |
--------------------------------------------------------------------------------
/NEWS.md:
--------------------------------------------------------------------------------
1 | ## SpaCET 1.3.0
2 |
3 | *2025-03-05*
4 |
5 | * Add cell references of hepatocytes and cholangiocytes so that SpaCET can infer their fractions when deconvolving liver cancer samples.
6 | * Update `SpaCET.deconvolution` to deconvolve normal tissues by setting`adjacentNormal = TRUE` to skip the malignant cell prediction.
7 | * Update `SpaCET.visualize.spatialFeature` to visualize secreted protein signaling activity and pattern.
8 |
9 | ## SpaCET 1.2.0
10 |
11 | *2024-07-06*
12 |
13 | * Add a new function `SpaCET.GeneSetScore` to calculate gene set score.
14 | * Update `convert.Seurat` and `addTo.Seurat` to be compatible with Seurat v5.
15 |
16 | ## SpaCET 1.1.0
17 |
18 | *2023-01-30*
19 |
20 | * Add an interactive visualization panel to browse the deconvolution and analysis results `SpaCET.visualize.spatialFeature(SpaCET_obj,interactive=TRUE)`.
21 | * Add a new function to combine both the tumor-immune interface and interaction spots `SpaCET.combine.interface()`.
22 |
23 | ## SpaCET 1.0.0
24 |
25 | *2022-12-20*
26 |
27 | * Release SpaCET package.
28 |
--------------------------------------------------------------------------------
/R/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/R/.DS_Store
--------------------------------------------------------------------------------
/README.Rmd:
--------------------------------------------------------------------------------
1 | ---
2 | output: github_document
3 | ---
4 |
5 |
6 |
7 | ```{r, include = FALSE}
8 | knitr::opts_chunk$set(
9 | collapse = TRUE,
10 | comment = "#>",
11 | fig.path = "man/figures/README-",
12 | out.width = "100%"
13 | )
14 | ```
15 |
16 | # SpaCET: Spatial Cellular Estimator for Tumors
17 |
18 |
19 |
20 |
21 | SpaCET is an R package designed for analyzing cancer spatial transcriptomics (ST) datasets to estimate cell lineages and intercellular interactions within the tumor microenvironment. In a nutshell, SpaCET first infers cancer cell abundance by integrating a gene pattern dictionary of common malignancies. Subsequently, SpaCET employs a constrained linear regression model to calibrate local tissue densities and determine stromal and immune cell lineage fractions based on a comprehensive non-malignant cell atlas. Furthermore, SpaCET has the capability to unveil putative cell-cell interactions within the tumor microenvironment, particularly at the tumor-immune interface. Of note, although SpaCET does not require any input cell references for the analysis of tumor ST data, SpaCET can still incorporate a matched scRNA-seq dataset as customized references to conduct cell type deconvolution of any ST dataset.
22 |
23 |
24 |
25 |
26 |
27 | ## Installation
28 |
29 | To install `SpaCET`, we recommend using `devtools`:
30 |
31 | ``` r
32 | # install.packages("devtools")
33 | devtools::install_github("data2intelligence/SpaCET")
34 | ```
35 |
36 | Or user can install `SpaCET` from the source code. Click here to download it.
37 |
38 | ``` r
39 | # install SpaCET in the R environment.
40 | install.packages("Path_to_the_source_code", repos = NULL, type="source")
41 | ```
42 |
43 | ## Dependencies
44 |
45 | * R version >= 4.2.0.
46 | * R packages: Matrix, jsonlite, ggplot2, reshape2, patchwork, png, shiny, plotly, DT, MUDAN, factoextra, NbClust, cluster, parallel, pbmcapply, psych, BiRewire, limma, arrow, UCell.
47 |
48 | ## Example
49 |
50 | ``` r
51 | library(SpaCET)
52 |
53 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
54 | SpaCET_obj <- create.SpaCET.object.10X(visiumPath = visiumPath)
55 | SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="BRCA", coreNo=6)
56 |
57 | SpaCET_obj@results$deconvolution$propMat[1:13,1:5]
58 |
59 | ## 50x102 59x19 14x94 47x13 73x43
60 | ## Malignant 2.860636e-01 1 6.845966e-02 3.899756e-01 9.608802e-01
61 | ## CAF 3.118545e-01 0 3.397067e-01 1.111980e-01 3.372692e-02
62 | ## Endothelial 5.510895e-02 0 1.427060e-01 3.080531e-02 5.263544e-03
63 | ## Plasma 2.213392e-02 0 1.507382e-02 1.183170e-02 9.071809e-06
64 | ## B cell 3.885793e-03 0 9.271616e-02 1.406470e-01 1.329085e-06
65 | ## T CD4 1.344389e-01 0 1.554305e-02 1.249414e-01 1.112392e-05
66 | ## T CD8 7.578696e-03 0 2.514558e-07 1.379856e-03 1.123043e-06
67 | ## NK 7.104005e-04 0 1.670019e-06 4.890387e-08 3.562557e-07
68 | ## cDC 1.421632e-07 0 8.278023e-02 7.584295e-02 2.851146e-07
69 | ## pDC 1.606443e-06 0 2.283754e-02 1.805671e-02 3.878344e-07
70 | ## Macrophage 1.703304e-01 0 5.021248e-02 9.531511e-02 9.253645e-07
71 | ## Mast 7.905067e-08 0 1.621498e-05 1.333430e-07 1.162099e-07
72 | ## Neutrophil 1.380073e-05 0 9.528996e-07 1.167503e-08 9.908635e-05
73 | ```
74 |
75 | ## Tutorial
76 | * [Cell type deconvolution and interaction analysis](https://data2intelligence.github.io/SpaCET/articles/visium_BC.html)
77 | * [Deconvolution with a matched scRNA-seq data set](https://data2intelligence.github.io/SpaCET/articles/oldST_PDAC.html)
78 | * [Application to high resolution spatial transcriptomics data](https://data2intelligence.github.io/SpaCET/articles/hiresST_CRC.html)
79 | * [Gene set score calculation for spatial spots](https://data2intelligence.github.io/SpaCET/articles/GeneSetScore.html)
80 |
81 | ## Citation
82 | Beibei Ru, Jinlin Huang, Yu Zhang, Kenneth Aldape, Peng Jiang. Estimation of cell lineages in tumors from spatial transcriptomics data. **Nature Communications** 14, 568 (2023). [Link]
83 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | # SpaCET: Spatial Cellular Estimator for Tumors
5 |
6 |
7 |
8 |
9 | SpaCET is an R package designed for analyzing cancer spatial
10 | transcriptomics (ST) datasets to estimate cell lineages and
11 | intercellular interactions within the tumor microenvironment. In a
12 | nutshell, SpaCET first infers cancer cell abundance by integrating a
13 | gene pattern dictionary of common malignancies. Subsequently, SpaCET
14 | employs a constrained linear regression model to calibrate local tissue
15 | densities and determine stromal and immune cell lineage fractions based
16 | on a comprehensive non-malignant cell atlas. Furthermore, SpaCET has the
17 | capability to unveil putative cell-cell interactions within the tumor
18 | microenvironment, particularly at the tumor-immune interface. Of note,
19 | although SpaCET does not require any input cell references for the
20 | analysis of tumor ST data, SpaCET can still incorporate a matched
21 | scRNA-seq dataset as customized references to conduct cell type
22 | deconvolution of any ST dataset.
23 |
24 |
25 |
26 | ## Installation
27 |
28 | To install `SpaCET`, we recommend using `devtools`:
29 |
30 | ``` r
31 | # install.packages("devtools")
32 | devtools::install_github("data2intelligence/SpaCET")
33 | ```
34 |
35 | Or user can install `SpaCET` from the source code. Click
36 | here
37 | to download it.
38 |
39 | ``` r
40 | # install SpaCET in the R environment.
41 | install.packages("Path_to_the_source_code", repos = NULL, type="source")
42 | ```
43 |
44 | ## Dependencies
45 |
46 | - R version \>= 4.2.0.
47 | - R packages: Matrix, jsonlite, ggplot2, reshape2, patchwork, png,
48 | shiny, plotly, DT, MUDAN, factoextra, NbClust, cluster, parallel,
49 | pbmcapply, psych, BiRewire, limma, arrow, UCell.
50 |
51 | ## Example
52 |
53 | ``` r
54 | library(SpaCET)
55 |
56 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
57 | SpaCET_obj <- create.SpaCET.object.10X(visiumPath = visiumPath)
58 | SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="BRCA", coreNo=6)
59 |
60 | SpaCET_obj@results$deconvolution$propMat[1:13,1:5]
61 |
62 | ## 50x102 59x19 14x94 47x13 73x43
63 | ## Malignant 2.860636e-01 1 6.845966e-02 3.899756e-01 9.608802e-01
64 | ## CAF 3.118545e-01 0 3.397067e-01 1.111980e-01 3.372692e-02
65 | ## Endothelial 5.510895e-02 0 1.427060e-01 3.080531e-02 5.263544e-03
66 | ## Plasma 2.213392e-02 0 1.507382e-02 1.183170e-02 9.071809e-06
67 | ## B cell 3.885793e-03 0 9.271616e-02 1.406470e-01 1.329085e-06
68 | ## T CD4 1.344389e-01 0 1.554305e-02 1.249414e-01 1.112392e-05
69 | ## T CD8 7.578696e-03 0 2.514558e-07 1.379856e-03 1.123043e-06
70 | ## NK 7.104005e-04 0 1.670019e-06 4.890387e-08 3.562557e-07
71 | ## cDC 1.421632e-07 0 8.278023e-02 7.584295e-02 2.851146e-07
72 | ## pDC 1.606443e-06 0 2.283754e-02 1.805671e-02 3.878344e-07
73 | ## Macrophage 1.703304e-01 0 5.021248e-02 9.531511e-02 9.253645e-07
74 | ## Mast 7.905067e-08 0 1.621498e-05 1.333430e-07 1.162099e-07
75 | ## Neutrophil 1.380073e-05 0 9.528996e-07 1.167503e-08 9.908635e-05
76 | ```
77 |
78 | ## Tutorial
79 |
80 | - [Cell type deconvolution and interaction
81 | analysis](https://data2intelligence.github.io/SpaCET/articles/visium_BC.html)
82 | - [Deconvolution with a matched scRNA-seq data
83 | set](https://data2intelligence.github.io/SpaCET/articles/oldST_PDAC.html)
84 | - [Application to high resolution spatial transcriptomics
85 | data](https://data2intelligence.github.io/SpaCET/articles/hiresST_CRC.html)
86 | - [Gene set score calculation for spatial
87 | spots](https://data2intelligence.github.io/SpaCET/articles/GeneSetScore.html)
88 |
89 | ## Citation
90 |
91 | Beibei Ru, Jinlin Huang, Yu Zhang, Kenneth Aldape, Peng Jiang.
92 | Estimation of cell lineages in tumors from spatial transcriptomics data.
93 | **Nature Communications** 14, 568 (2023).
94 | \[Link\]
95 |
--------------------------------------------------------------------------------
/SpaCET.Rproj:
--------------------------------------------------------------------------------
1 | Version: 1.0
2 |
3 | RestoreWorkspace: Default
4 | SaveWorkspace: Default
5 | AlwaysSaveHistory: Default
6 |
7 | EnableCodeIndexing: Yes
8 | UseSpacesForTab: Yes
9 | NumSpacesForTab: 2
10 | Encoding: UTF-8
11 |
12 | RnwWeave: Sweave
13 | LaTeX: pdfLaTeX
14 |
15 | AutoAppendNewline: Yes
16 | StripTrailingWhitespace: Yes
17 |
18 | BuildType: Package
19 | PackageUseDevtools: Yes
20 | PackageInstallArgs: --no-multiarch --with-keep.source
21 |
--------------------------------------------------------------------------------
/_pkgdown.yml:
--------------------------------------------------------------------------------
1 | url: ~
2 | template:
3 | bootstrap: 5
4 |
5 | navbar:
6 | left:
7 | - icon: fas fa-home fa-lg
8 | href: index.html
9 | - text: Reference
10 | href: reference/index.html
11 | - text: Tutorials
12 | menu:
13 | - text: Core
14 | - text: Cell type deconvolution and interaction analysis
15 | href: articles/visium_BC.html
16 | - text: Deconvolution with a matched scRNA-seq data set
17 | href: articles/oldST_PDAC.html
18 | - text: Application to high resolution spatial transcriptomics data
19 | href: articles/hiresST_CRC.html
20 | - text: ----
21 | - text: Misc
22 | - text: Gene set score calculation for spatial spots
23 | href: articles/GeneSetScore.html
24 | - text: News
25 | href: news/index.html
26 |
27 | reference:
28 | - title: SpaCET object
29 | contents:
30 | - SpaCET-class
31 | - create.SpaCET.object
32 | - create.SpaCET.object.10X
33 | - SpaCET.quality.control
34 | - SpaCET.quality.control
35 | - SpaCET.quality.control
36 | - convert.Seurat
37 | - addTo.Seurat
38 |
39 | - title: Deconvolution of ST data
40 | contents:
41 | - SpaCET.deconvolution
42 | - SpaCET.deconvolution.malignant
43 | - SpaCET.deconvolution.matched.scRNAseq
44 | - SpaCET.deconvolution.malignant.customized.scRNAseq
45 |
46 | - title: Cell-cell interaction analysis
47 | contents:
48 | - SpaCET.CCI.colocalization
49 | - SpaCET.CCI.LRNetworkScore
50 | - SpaCET.CCI.cellTypePair
51 |
52 | - title: Tumor-Stroma Interface
53 | contents:
54 | - SpaCET.identify.interface
55 | - SpaCET.combine.interface
56 | - SpaCET.distance.to.interface
57 |
58 | - title: Visualization
59 | contents:
60 | - SpaCET.visualize.spatialFeature
61 | - SpaCET.visualize.colocalization
62 | - SpaCET.visualize.cellTypePair
63 |
64 | - title: Gene set score calculation
65 | contents:
66 | - SpaCET.GeneSetScore
67 | - read.gmt
68 | - write.gmt
69 |
--------------------------------------------------------------------------------
/docs/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/.DS_Store
--------------------------------------------------------------------------------
/docs/404.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Page not found (404) • SpaCET
9 |
10 |
11 |
12 |
13 |
14 |
18 |
19 |
20 | Skip to contents
21 |
22 |
23 |
78 |
79 |
83 |
84 | Content not found. Please use links in the navbar.
85 |
86 |
87 |
88 |
89 |
90 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
--------------------------------------------------------------------------------
/docs/articles/img/CAF-M2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/CAF-M2.png
--------------------------------------------------------------------------------
/docs/articles/img/CCC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/CCC.png
--------------------------------------------------------------------------------
/docs/articles/img/GS1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/GS1.png
--------------------------------------------------------------------------------
/docs/articles/img/GS2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/GS2.png
--------------------------------------------------------------------------------
/docs/articles/img/GS3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/GS3.png
--------------------------------------------------------------------------------
/docs/articles/img/LRNetworkScore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/LRNetworkScore.png
--------------------------------------------------------------------------------
/docs/articles/img/PDAC_CCC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/PDAC_CCC.png
--------------------------------------------------------------------------------
/docs/articles/img/PDAC_expr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/PDAC_expr.png
--------------------------------------------------------------------------------
/docs/articles/img/PDAC_prop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/PDAC_prop.png
--------------------------------------------------------------------------------
/docs/articles/img/QC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/QC.png
--------------------------------------------------------------------------------
/docs/articles/img/cancerCellState.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/cancerCellState.png
--------------------------------------------------------------------------------
/docs/articles/img/cancerDictionary.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/cancerDictionary.png
--------------------------------------------------------------------------------
/docs/articles/img/cancerInterface1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/cancerInterface1.png
--------------------------------------------------------------------------------
/docs/articles/img/cancerInterface2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/cancerInterface2.png
--------------------------------------------------------------------------------
/docs/articles/img/cancerInterface3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/cancerInterface3.png
--------------------------------------------------------------------------------
/docs/articles/img/slideseq_anno.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/slideseq_anno.png
--------------------------------------------------------------------------------
/docs/articles/img/slideseq_prop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/slideseq_prop.png
--------------------------------------------------------------------------------
/docs/articles/img/visualizeDeconvolution.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/visualizeDeconvolution.png
--------------------------------------------------------------------------------
/docs/articles/img/visualizeDeconvolution2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/visualizeDeconvolution2.png
--------------------------------------------------------------------------------
/docs/articles/img/visualizeDeconvolution3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/articles/img/visualizeDeconvolution3.png
--------------------------------------------------------------------------------
/docs/articles/index.html:
--------------------------------------------------------------------------------
1 |
2 | Articles • SpaCET
6 | Skip to contents
7 |
8 |
9 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
--------------------------------------------------------------------------------
/docs/authors.html:
--------------------------------------------------------------------------------
1 |
2 | Authors and Citation • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
63 |
64 |
76 |
77 |
78 |
Citation
79 |
Source: DESCRIPTION
80 |
81 |
Ru B, Jiang P (2025).
82 | SpaCET: Spatial Cellular Estimator for Tumors.
83 | R package version 1.3.0, https://github.com/data2intelligence/SpaCET.
84 |
85 |
@Manual{,
86 | title = {SpaCET: Spatial Cellular Estimator for Tumors},
87 | author = {Beibei Ru and Peng Jiang},
88 | year = {2025},
89 | note = {R package version 1.3.0},
90 | url = {https://github.com/data2intelligence/SpaCET},
91 | }
92 |
93 |
95 |
96 |
97 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/docs/deps/data-deps.txt:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/docs/link.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
13 |
--------------------------------------------------------------------------------
/docs/news/index.html:
--------------------------------------------------------------------------------
1 |
2 | Changelog • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
64 |
65 |
66 |
SpaCET 1.3.0
67 |
2025-03-05
68 |
- Add cell references of hepatocytes and cholangiocytes so that SpaCET can infer their fractions when deconvolving liver cancer samples.
69 | - Update
SpaCET.deconvolution
to deconvolve normal tissues by settingadjacentNormal = TRUE
to skip the malignant cell prediction.
70 | - Update
SpaCET.visualize.spatialFeature
to visualize secreted protein signaling activity and pattern.
71 |
72 |
73 |
SpaCET 1.2.0
74 |
2024-07-06
75 |
- Add a new function
SpaCET.GeneSetScore
to calculate gene set score.
76 | - Update
convert.Seurat
and addTo.Seurat
to be compatible with Seurat v5.
77 |
78 |
79 |
SpaCET 1.1.0
80 |
2023-01-30
81 |
- Add an interactive visualization panel to browse the deconvolution and analysis results
SpaCET.visualize.spatialFeature(SpaCET_obj,interactive=TRUE)
.
82 | - Add a new function to combine both the tumor-immune interface and interaction spots
SpaCET.combine.interface()
.
83 |
84 |
85 |
SpaCET 1.0.0
86 |
2022-12-20
87 |
- Release SpaCET package.
88 |
89 |
91 |
92 |
93 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
--------------------------------------------------------------------------------
/docs/pkgdown.js:
--------------------------------------------------------------------------------
1 | /* http://gregfranko.com/blog/jquery-best-practices/ */
2 | (function($) {
3 | $(function() {
4 |
5 | $('nav.navbar').headroom();
6 |
7 | Toc.init({
8 | $nav: $("#toc"),
9 | $scope: $("main h2, main h3, main h4, main h5, main h6")
10 | });
11 |
12 | if ($('#toc').length) {
13 | $('body').scrollspy({
14 | target: '#toc',
15 | offset: $("nav.navbar").outerHeight() + 1
16 | });
17 | }
18 |
19 | // Activate popovers
20 | $('[data-bs-toggle="popover"]').popover({
21 | container: 'body',
22 | html: true,
23 | trigger: 'focus',
24 | placement: "top",
25 | sanitize: false,
26 | });
27 |
28 | $('[data-bs-toggle="tooltip"]').tooltip();
29 |
30 | /* Clipboard --------------------------*/
31 |
32 | function changeTooltipMessage(element, msg) {
33 | var tooltipOriginalTitle=element.getAttribute('data-original-title');
34 | element.setAttribute('data-original-title', msg);
35 | $(element).tooltip('show');
36 | element.setAttribute('data-original-title', tooltipOriginalTitle);
37 | }
38 |
39 | if(ClipboardJS.isSupported()) {
40 | $(document).ready(function() {
41 | var copyButton = "";
42 |
43 | $("div.sourceCode").addClass("hasCopyButton");
44 |
45 | // Insert copy buttons:
46 | $(copyButton).prependTo(".hasCopyButton");
47 |
48 | // Initialize tooltips:
49 | $('.btn-copy-ex').tooltip({container: 'body'});
50 |
51 | // Initialize clipboard:
52 | var clipboard = new ClipboardJS('[data-clipboard-copy]', {
53 | text: function(trigger) {
54 | return trigger.parentNode.textContent.replace(/\n#>[^\n]*/g, "");
55 | }
56 | });
57 |
58 | clipboard.on('success', function(e) {
59 | changeTooltipMessage(e.trigger, 'Copied!');
60 | e.clearSelection();
61 | });
62 |
63 | clipboard.on('error', function() {
64 | changeTooltipMessage(e.trigger,'Press Ctrl+C or Command+C to copy');
65 | });
66 |
67 | });
68 | }
69 |
70 | /* Search marking --------------------------*/
71 | var url = new URL(window.location.href);
72 | var toMark = url.searchParams.get("q");
73 | var mark = new Mark("main#main");
74 | if (toMark) {
75 | mark.mark(toMark, {
76 | accuracy: {
77 | value: "complementary",
78 | limiters: [",", ".", ":", "/"],
79 | }
80 | });
81 | }
82 |
83 | /* Search --------------------------*/
84 | /* Adapted from https://github.com/rstudio/bookdown/blob/2d692ba4b61f1e466c92e78fd712b0ab08c11d31/inst/resources/bs4_book/bs4_book.js#L25 */
85 | // Initialise search index on focus
86 | var fuse;
87 | $("#search-input").focus(async function(e) {
88 | if (fuse) {
89 | return;
90 | }
91 |
92 | $(e.target).addClass("loading");
93 | var response = await fetch($("#search-input").data("search-index"));
94 | var data = await response.json();
95 |
96 | var options = {
97 | keys: ["what", "text", "code"],
98 | ignoreLocation: true,
99 | threshold: 0.1,
100 | includeMatches: true,
101 | includeScore: true,
102 | };
103 | fuse = new Fuse(data, options);
104 |
105 | $(e.target).removeClass("loading");
106 | });
107 |
108 | // Use algolia autocomplete
109 | var options = {
110 | autoselect: true,
111 | debug: true,
112 | hint: false,
113 | minLength: 2,
114 | };
115 | var q;
116 | async function searchFuse(query, callback) {
117 | await fuse;
118 |
119 | var items;
120 | if (!fuse) {
121 | items = [];
122 | } else {
123 | q = query;
124 | var results = fuse.search(query, { limit: 20 });
125 | items = results
126 | .filter((x) => x.score <= 0.75)
127 | .map((x) => x.item);
128 | if (items.length === 0) {
129 | items = [{dir:"Sorry 😿",previous_headings:"",title:"No results found.",what:"No results found.",path:window.location.href}];
130 | }
131 | }
132 | callback(items);
133 | }
134 | $("#search-input").autocomplete(options, [
135 | {
136 | name: "content",
137 | source: searchFuse,
138 | templates: {
139 | suggestion: (s) => {
140 | if (s.title == s.what) {
141 | return `${s.dir} > ${s.title}
`;
142 | } else if (s.previous_headings == "") {
143 | return `${s.dir} > ${s.title}
> ${s.what}`;
144 | } else {
145 | return `${s.dir} > ${s.title}
> ${s.previous_headings} > ${s.what}`;
146 | }
147 | },
148 | },
149 | },
150 | ]).on('autocomplete:selected', function(event, s) {
151 | window.location.href = s.path + "?q=" + q + "#" + s.id;
152 | });
153 | });
154 | })(window.jQuery || window.$)
155 |
156 |
157 |
--------------------------------------------------------------------------------
/docs/pkgdown.yml:
--------------------------------------------------------------------------------
1 | pandoc: 3.1.1
2 | pkgdown: 2.0.7
3 | pkgdown_sha: ~
4 | articles:
5 | GeneSetScore: GeneSetScore.html
6 | hiresST_CRC: hiresST_CRC.html
7 | oldST_PDAC: oldST_PDAC.html
8 | visium_BC: visium_BC.html
9 | last_built: 2025-03-24T17:17Z
10 |
11 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET-class.html:
--------------------------------------------------------------------------------
1 |
2 | Define the SpaCET object — SpaCET-class • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Define the SpaCET object
68 |
69 |
70 |
71 |
72 |
Slots
73 |
74 |
75 |
input
76 | The input data
77 |
78 |
79 | results
80 | The results
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.CCI.cellTypePair.html:
--------------------------------------------------------------------------------
1 |
2 | Ligand-Receptor analysis for a co-localized cell-type pair — SpaCET.CCI.cellTypePair • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Test the co-expression of ligands and receptors within the same ST spot for the co-localized cell-type pairs.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.CCI.cellTypePair(SpaCET_obj, cellTypePair)
73 |
74 |
75 |
76 |
Arguments
77 |
- SpaCET_obj
78 | A SpaCET object.
79 |
80 |
81 | - cellTypePair
82 | A pair of cell-types.
83 |
84 |
85 |
86 |
Value
87 |
88 |
89 |
A SpaCET object.
90 |
91 |
92 |
93 |
Examples
94 |
SpaCET_obj <- SpaCET.CCI.cellTypePair(SpaCET_obj, cellTypePair=c("CAF","Macrophage M2"))
95 |
96 |
97 |
99 |
100 |
101 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.CCI.colocalization.html:
--------------------------------------------------------------------------------
1 |
2 | Cell-cell colocalization analysis — SpaCET.CCI.colocalization • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Calculate the cell-type pair colocalization by using Spearman correlation analysis.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.CCI.colocalization(SpaCET_obj)
73 |
74 |
75 |
76 |
Arguments
77 |
- SpaCET_obj
78 | A SpaCET object.
79 |
80 |
81 |
82 |
Value
83 |
84 |
85 |
A SpaCET object.
86 |
87 |
88 |
89 |
Examples
90 |
SpaCET_obj <- SpaCET.CCI.colocalization(SpaCET_obj)
91 |
92 |
93 |
95 |
96 |
97 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.deconvolution.html:
--------------------------------------------------------------------------------
1 |
2 | Deconvolve tumor ST data set — SpaCET.deconvolution • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Estimate the cell fraction of cell lineages and sub lineages.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.deconvolution(
73 | SpaCET_obj,
74 | cancerType,
75 | adjacentNormal = FALSE,
76 | coreNo = 6
77 | )
78 |
79 |
80 |
81 |
Arguments
82 |
- SpaCET_obj
83 | A SpaCET object.
84 |
85 |
86 | - cancerType
87 | Cancer type of the current tumor ST dataset.
88 |
89 |
90 | - adjacentNormal
91 | Indicate whether your sample is normal tissue adjacent to the tumor. If TURE, SpaCET will skip the stage of malignant cell inference. Default: FALSE.
92 |
93 |
94 | - coreNo
95 | Core number in parallel computation.
96 |
97 |
98 |
99 |
Value
100 |
101 |
102 |
A SpaCET object.
103 |
104 |
105 |
106 |
Examples
107 |
SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="BRCA", coreNo=6)
108 |
109 |
110 |
112 |
113 |
114 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.deconvolution.malignant.html:
--------------------------------------------------------------------------------
1 |
2 | Deconvolve malignant cell fraction — SpaCET.deconvolution.malignant • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Explore different malignant cell states in tumor ST dataset.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.deconvolution.malignant(
73 | SpaCET_obj,
74 | Malignant = "Malignant",
75 | malignantCutoff = 0.7,
76 | coreNo = 6
77 | )
78 |
79 |
80 |
81 |
Arguments
82 |
- SpaCET_obj
83 | A SpaCET object.
84 |
85 |
86 | - Malignant
87 | Indicates the name of malignant cell type in the major lineage layer from the deconvolution results. Default: "Malignant".
88 |
89 |
90 | - malignantCutoff
91 | Fraction cutoff for defining spots with high abundant malignant cells. Default: 0.7.
92 |
93 |
94 | - coreNo
95 | Core number in parallel.
96 |
97 |
98 |
99 |
Value
100 |
101 |
102 |
A SpaCET object
103 |
104 |
105 |
106 |
Examples
107 |
SpaCET_obj <- SpaCET.deconvolution.malignant(SpaCET_obj)
108 |
109 |
110 |
112 |
113 |
114 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.identify.interface.html:
--------------------------------------------------------------------------------
1 |
2 | Identify tumor-stroma interface — SpaCET.identify.interface • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Identify the spots at the tumor-stroma interface.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.identify.interface(
73 | SpaCET_obj,
74 | Malignant = "Malignant",
75 | MalignantCutoff = 0.5
76 | )
77 |
78 |
79 |
80 |
Arguments
81 |
- SpaCET_obj
82 | A SpaCET object.
83 |
84 |
85 | - Malignant
86 | Indicates the name of malignant cell type in the major lineage layer from the deconvolution results. Default: "Malignant".
87 |
88 |
89 | - MalignantCutoff
90 | Malignant cell fraction cutoff for tumor boundary. Default: 0.5.
91 |
92 |
93 |
94 |
Value
95 |
96 |
97 |
A SpaCET object.
98 |
99 |
100 |
101 |
Examples
102 |
105 |
106 |
108 |
109 |
110 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.quality.control.html:
--------------------------------------------------------------------------------
1 |
2 | Filter spatial spots and calculate the QC metrics — SpaCET.quality.control • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Spots with less than `min.genes` expressed genes would be removed.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.quality.control(SpaCET_obj, min.genes = 1)
73 |
74 |
75 |
76 |
Arguments
77 |
- SpaCET_obj
78 | A SpaCET object.
79 |
80 |
81 | - min.genes
82 | Minimum number of expressed genes. Default: 1.
83 |
84 |
85 |
86 |
Value
87 |
88 |
89 |
A SpaCET object.
90 |
91 |
92 |
93 |
Examples
94 |
SpaCET_obj <- SpaCET.quality.control(SpaCET_obj)
95 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "QualityControl", spatialFeatures=c("UMI","Gene"))
96 |
97 |
98 |
100 |
101 |
102 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.visualize.cellTypePair.html:
--------------------------------------------------------------------------------
1 |
2 | Cell-type pair visualization — SpaCET.visualize.cellTypePair • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Visualize the interaction analysis of a co-localized cell-type pair.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.visualize.cellTypePair(SpaCET_obj, cellTypePair)
73 |
74 |
75 |
76 |
Arguments
77 |
- SpaCET_obj
78 | A SpaCET object.
79 |
80 |
81 | - cellTypePair
82 | A pair of cell types.
83 |
84 |
85 |
86 |
Value
87 |
88 |
89 |
A ggplot object.
90 |
91 |
92 |
93 |
Examples
94 |
SpaCET.visualize.cellTypePair(SpaCET_obj, cellTypePair=c("CAF","Macrophage M2"))
95 |
96 |
97 |
99 |
100 |
101 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
--------------------------------------------------------------------------------
/docs/reference/SpaCET.visualize.colocalization.html:
--------------------------------------------------------------------------------
1 |
2 | Cell-cell colocalization visualization — SpaCET.visualize.colocalization • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Visualize the cell-type pair colocalization.
68 |
69 |
70 |
71 |
Usage
72 |
SpaCET.visualize.colocalization(SpaCET_obj)
73 |
74 |
75 |
76 |
Arguments
77 |
- SpaCET_obj
78 | A SpaCET object.
79 |
80 |
81 |
82 |
Value
83 |
84 |
85 |
A ggplot object.
86 |
87 |
88 |
89 |
Examples
90 |
SpaCET.visualize.colocalization(SpaCET_obj)
91 |
92 |
93 |
95 |
96 |
97 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/docs/reference/figures/sticker.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/reference/figures/sticker.png
--------------------------------------------------------------------------------
/docs/reference/figures/workflow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/docs/reference/figures/workflow.png
--------------------------------------------------------------------------------
/docs/reference/read.gmt.html:
--------------------------------------------------------------------------------
1 |
2 | Read a gmt file — read.gmt • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Read a gmt file as a gene set list.
68 |
69 |
70 |
74 |
75 |
76 |
Arguments
77 |
- gmtPath
78 | Path to a gmt file.
79 |
80 |
81 |
82 |
Value
83 |
84 |
85 |
A gene set list
86 |
87 |
88 |
89 |
Examples
90 |
gmt <- read.gmt(gmtPath)
91 |
92 |
93 |
95 |
96 |
97 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/docs/reference/write.gmt.html:
--------------------------------------------------------------------------------
1 |
2 | Write a gmt file — write.gmt • SpaCET
6 | Skip to contents
7 |
8 |
9 |
59 |
60 |
65 |
66 |
67 |
Write a gene set list as a gmt file.
68 |
69 |
70 |
74 |
75 |
76 |
Arguments
77 |
- gmt
78 | A gene set list.
79 |
80 |
81 | - gmtPath
82 | Path to a gmt file.
83 |
84 |
85 |
86 |
87 |
Examples
88 |
write.gmt(gmt, gmtPath)
89 |
90 |
91 |
93 |
94 |
95 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
--------------------------------------------------------------------------------
/docs/sitemap.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | /404.html
5 |
6 |
7 | /LICENSE-text.html
8 |
9 |
10 | /articles/GeneSetScore.html
11 |
12 |
13 | /articles/hiresST_CRC.html
14 |
15 |
16 | /articles/index.html
17 |
18 |
19 | /articles/oldST_PDAC.html
20 |
21 |
22 | /articles/visium_BC.html
23 |
24 |
25 | /authors.html
26 |
27 |
28 | /index.html
29 |
30 |
31 | /news/index.html
32 |
33 |
34 | /reference/SpaCET-class.html
35 |
36 |
37 | /reference/SpaCET.CCI.LRNetworkScore.html
38 |
39 |
40 | /reference/SpaCET.CCI.cellTypePair.html
41 |
42 |
43 | /reference/SpaCET.CCI.colocalization.html
44 |
45 |
46 | /reference/SpaCET.GeneSetScore.html
47 |
48 |
49 | /reference/SpaCET.combine.interface.html
50 |
51 |
52 | /reference/SpaCET.deconvolution.html
53 |
54 |
55 | /reference/SpaCET.deconvolution.malignant.customized.scRNAseq.html
56 |
57 |
58 | /reference/SpaCET.deconvolution.malignant.html
59 |
60 |
61 | /reference/SpaCET.deconvolution.matched.scRNAseq.html
62 |
63 |
64 | /reference/SpaCET.distance.to.interface.html
65 |
66 |
67 | /reference/SpaCET.identify.interface.html
68 |
69 |
70 | /reference/SpaCET.quality.control.html
71 |
72 |
73 | /reference/SpaCET.visualize.cellTypePair.html
74 |
75 |
76 | /reference/SpaCET.visualize.colocalization.html
77 |
78 |
79 | /reference/SpaCET.visualize.spatialFeature.html
80 |
81 |
82 | /reference/addTo.Seurat.html
83 |
84 |
85 | /reference/convert.Seurat.html
86 |
87 |
88 | /reference/create.SpaCET.object.10X.html
89 |
90 |
91 | /reference/create.SpaCET.object.html
92 |
93 |
94 | /reference/index.html
95 |
96 |
97 | /reference/read.gmt.html
98 |
99 |
100 | /reference/write.gmt.html
101 |
102 |
103 |
--------------------------------------------------------------------------------
/inst/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/GeneSets/CancerCellState.gmt:
--------------------------------------------------------------------------------
1 | CancerCellState_Cycle ACYP1 ANLN ANP32B ANP32E APITD1 APOBEC3B ARHGAP11A ARHGAP11B ARL6IP1 ARL6IP6 ASF1B ASPM ATAD2 ATAD5 AURKA AURKB BARD1 BCL2L12 BIRC5 BORA BRCA1 BTG3 BUB1 BUB1B C12orf75 C19orf48 C21orf58 CALM2 CALM3 CARHSP1 CASC5 CCDC34 CCNA2 CCNB1 CCNB2 CCNE1 CCNE2 CCT5 CDC20 CDC25B CDC45 CDC6 CDCA2 CDCA3 CDCA4 CDCA5 CDCA7 CDCA8 CDK1 CDKN3 CDT1 CENPA CENPE CENPF CENPH CENPK CENPM CENPN CENPU CENPW CEP55 CHAF1A CHEK1 CKAP2 CKAP2L CKAP5 CKLF CKS1B CKS2 CLSPN CMC2 CNIH4 CRNDE DBF4 DDX39A DEK DEPDC1 DEPDC1B DHFR DIAPH3 DLGAP5 DNAJC9 DNMT1 DONSON DSN1 DTL DTYMK DUT E2F1 ECT2 EZH2 FADS1 FAM111A FAM111B FAM64A FAM83D FANCA FANCD2 FANCI FBLN1 FBXO5 FEN1 FOXM1 GGCT GGH GINS2 GMNN GPSM2 GTSE1 H1F0 H2AFV H2AFX H2AFZ HAUS1 HELLS HINT1 HIRIP3 HIST1H1D HIST1H1E HIST1H2BJ HIST1H4C HIST2H2AC HJURP HMG20B HMGB1 HMGB2 HMGB3 HMGN2 HMMR HN1 HNRNPA1 HNRNPA2B1 HPRT1 HSPD1 ILF2 IQGAP3 ITGB3BP JPT1 KIAA0101 KIAA1524 KIF11 KIF14 KIF15 KIF18A KIF20A KIF20B KIF22 KIF23 KIF2C KIF4A KIFC1 KNSTRN KPNA2 LIG1 LMNB1 LMNB2 LSM4 LSM5 MAD2L1 MAPRE1 MCM10 MCM2 MCM3 MCM4 MCM5 MCM6 MCM7 MELK MIS18A MIS18BP1 MKI67 MLF1IP MMS22L MND1 MNS1 MSH2 MSH6 MTHFD1 MXD3 MYBL2 MZT1 NAP1L1 NASP NCAPD2 NCAPD3 NCAPG NCAPG2 NDC80 NEK2 NMU NRM NUCB2 NUCKS1 NUDT1 NUF2 NUSAP1 OIP5 ORC6 PAQR4 PARPBP PBK PCLAF PCNA PHF19 PIF1 PKMYT1 PLK1 POC1A POLD3 PRC1 PRIM1 PRKDC PRR11 PSIP1 PSMC3IP PSRC1 PTMA PTMS PTN PTTG1 RACGAP1 RAD21 RAD51 RAD51AP1 RAD51C RAN RANBP1 RBL1 RECQL4 RFC2 RFC3 RFC4 RFC5 RMI2 RNASEH2A RNASEH2B RNF26 RPA2 RPA3 RRM1 RRM2 SAPCD2 SGOL1 SGOL2 SHCBP1 SIVA1 SKA2 SKA3 SLBP SLC25A5 SLC43A3 SMC1A SMC2 SMC4 SNRNP25 SNRPB SNRPD1 SPAG5 SPC24 SPC25 SPDL1 STMN1 STRA13 SUN2 SYT8 TACC3 TCF19 TEX30 TFDP1 TK1 TMEM106C TMEM97 TMPO TNFAIP8L1 TOP2A TPX2 TRIP13 TROAP TTK TUBA1B TUBA1C TUBB TUBB4B TUBB6 TUBG1 TYMS UBE2C UBE2S UBE2T UHRF1 UNG USP1 VRK1 WDR34 WDR76 ZWILCH ZWINT
2 | CancerCellState_Stress ABHD3 AC016629.8 ADAMTS1 ANKRD28 ANKRD37 ARC AREG ARID5B ARL5B ATF3 B3GNT5 BAG3 BAMBI BBC3 BHLHE40 BIRC3 BRD2 BTG1 BTG2 C10orf10 C11orf96 C16orf98 C1orf63 C5orf45 C8orf4 CA12 CCL20 CCNL1 CCP110 CD55 CDKN1A CDKN2AIP CEBPB CEBPD CITED2 CLDN3 CLDN4 CLK1 CSRNP1 CXCL1 CXCL2 CXCL3 CXCL5 CXCL8 CYP1B1 CYR61 DAPP1 DEPP1 DNAJA1 DNAJA4 DNAJB1 DNAJB4 DSC3 DUSP1 DUSP10 DUSP14 DUSP2 DUSP5 EDN1 EFNA1 EGR1 EGR2 EGR3 EHF EIF4A2 ELF3 EMP1 EPHA2 EREG ERRFI1 ETS2 FADS3 FAM133B FAM46A FAM53C FGFR3 FHL2 FKBP4 FOS FOSB FOSL1 FOSL2 FRMD4B FUS GADD45A GADD45B GADD45G GDF15 GEM GOLGB1 HBEGF HES1 HEXIM1 HNRNPU-AS1 HSP90AA1 HSPA1A HSPA1B HSPA5 HSPA6 HSPA8 HSPB1 HSPH1 ID1 ID2 IER2 IER3 IER5 IFRD1 IL8 IRX2 ITPKC JAG1 JUN JUNB JUND KCNQ1OT1 KDM6B KIAA1683 KLF10 KLF2 KLF4 KLF5 KLF6 LDLR LIF LIMA1 LINC00910 LINC00936 LMNA MAFB MAFF MALAT1 MAP3K8 MCL1 METTL15 MIDN MIR222HG MIR24-2 MIR3064 MKNK2 MXD1 MYADM MYC MYLIP NAMPT NCOA7 NEAT1 NEDD9 NFKBIA NFKBID NFKBIZ NOP58 NPAS4 NR4A1 NR4A2 NRARP NSUN6 OVOL1 PDK4 PDLIM3 PGM2L1 PHLDA1 PHLDA2 PIM1 PIM3 PLAUR PLK2 PLK3 PMAIP1 PNRC1 POLG2 PPP1R10 PPP1R15A PRKCA PRPF40A PTGS2 PTRHD1 RAB11FIP1 RAB3IP RALGDS RASD1 RDH10 REL RGS2 RHOB RND1 RND3 RP1-313I6.12 RP11-182L21.6 RP5-821D11.7 RP6-99M1.2 RRAD SEMA4A SERTAD1 SFN SIK1 SLC20A1 SLC38A2 SNHG12 SOCS1 SOCS3 SOX4 SOX9 SQSTM1 TACSTD2 TAF1D TCF7 TCIM TFRC TGIF1 TIPARP TLE4 TM4SF1 TNFAIP2 TNFAIP3 TRIB1 TSC22D1 TSC22D3 UBC UGDH VPS37B WEE1 YBX3 YME1L1 YOD1 ZBTB43 ZC3H12A ZFAND2A ZFP36 ZFP36L1 ZFP36L2 ZNF165 ZNF430
3 | CancerCellState_Interferon ACTN1 APOL1 APOL2 APOL3 APOL6 B2M BST2 C19orf66 C1R C1S C3 C5orf56 CCL2 CCL27 CCL5 CD74 CFB CFH CMPK2 CX3CL1 CXCL10 CXCL11 CXCL9 DDX58 DDX60 DDX60L DYNLT1 EIF2AK2 EPSTI1 ETV7 FXYD5 GBP1 GBP2 GBP3 GBP4 GBP5 GLUL HAPLN3 HELZ2 HERC5 HERC6 HLA-A HLA-B HLA-C HLA-DMA HLA-DMB HLA-DPA1 HLA-DPB1 HLA-DQA1 HLA-DQA2 HLA-DQB1 HLA-DRA HLA-DRB1 HLA-DRB5 HLA-E HLA-F HSPB8 ICAM1 IDO1 IFI16 IFI27 IFI35 IFI44 IFI44L IFI6 IFIH1 IFIT1 IFIT2 IFIT3 IFITM1 IFITM2 IFITM3 IL32 IRF1 IRF7 ISG15 ISG20 KLHDC7B LAMP3 LAP3 LGALS3BP LGALS9 LY6E MDK MSRB1 MX1 MX2 NNMT NT5C3A NUB1 OAS1 OAS2 OAS3 OASL PARP14 PARP9 PDZK1IP1 PLSCR1 PSMB10 PSMB8 PSMB9 PSME1 PSME2 RARRES3 RNF213 RSAD2 RTP4 SAA1 SAMD9 SAMD9L SAMHD1 SERPING1 SERPINH1 SLFN5 SOD2 SP100 SP110 SPP1 SQRDL STAT1 TAP1 TAP2.1 TAPBP TGM2 TNFSF10 TNFSF13B TRIM22 TYMP UBD UBE2L6 USP18 VCAM1 WARS XAF1 ZC3HAV1 ZNFX1
4 | CancerCellState_Hypoxia ADM AHNAK ALDOA ANGPTL4 BLNK BNIP3 BNIP3L C4orf3 CA9 CASP14 DDIT4 DHRS3 EGLN3 ENO2 EPAS1 ERO1L FAM162A FUT11 HILPDA HK2 IGFBP3 LDHA LINC01133 MGP NDRG1 NDUFA4L2 NRN1 P4HA1 PDK1 PFKFB3 PFKP PGF PGK1 PLIN2 PLOD2 PTHLH RGCC SLC16A1 SLC16A3 SLC2A1 SLC2A3 SLC6A8 SNCG SPAG4 TMEM91 VEGFA
5 | CancerCellState_Oxphos ATOX1 ATP5H C14orf2 COX14 MYEOV2 NDUFA1 NDUFA12 NDUFA3 NDUFB3 NDUFS6 NME1 PET100 POLR2I POLR2L RBX1 ROMO1 SCAND1 SEPW1 SLIRP TIMM8B TXNDC17 UQCR10 USMG5 UXT
6 | CancerCellState_Metal FKBP5 HEY1 HTRA1 MT1F MT1G MT1H MT1M PMP2 TPST1
7 | CancerCellState_cEMT AQP1 BGN CALD1 CCDC80 COL1A1 COL1A2 COL3A1 COL5A2 COL6A1 COL6A3 CPE FN1 GJA1 GNG11 NPC2 NRP2 SDC2 SPARC
8 | CancerCellState_pEMT ACTB ACTG1 ADIRF AKAP12 AKR1C1 ANXA1 ANXA2 ANXA3 ANXA5 ARL4C ARPC1B BCAM BPGM C19orf33 CAPN2 CD151 CD24 CD44 CD59 CD68 CD9 CD99 CDA CDKN2A CFL1 CHI3L1 CLIC1 COTL1 CRIP1 CSTB CTGF CTSB DKK1 ECM1 EIF4EBP1 EIF5A EMP3 ENO1 F3 FLNA FLNB FSTL3 FTL G0S2 G6PD GAPDH GJB6 GLO1 GPI GPX1 HMGA1 IGFBP2 IGFBP6 IGFBP7 INHBA ITGA6 ITGB1 ITGB6 ITGB8 ITM2B KLK6 KRT17 KRT18 KRT19 KRT7 KRT8 KYNU LAMA3 LAMB3 LAMC2 LGALS1 LGALS3 LINC00152 MGST1 MIF MMP1 MMP3 MT1E MT2A MYH9 MYL12B MYL6 MYO1B OCIAD2 ODC1 PDLIM4 PDLIM7 PDPN PFN1 PFN2 PGAM1 PKM PLA2G16 PLAU PLEK2 PLP2 PMEPA1 PODXL PRKCDBP PRSS23 PTRF RBP1 RHOC RHOD S100A10 S100A11 S100A13 S100A16 S100A2 S100A6 SERINC2 SERPINE1 SERPINE2 SH3BGRL3 SLC25A6 SLC38A5 SMS SPINK6 STEAP4 STOM SULT1E1 TAGLN TAGLN2 TGFBI THBS1 TIMP1 TIMP3 TMSB10 TMSB4X TNC TNFRSF12A TNFRSF21 TNFRSF6B TPM1 TPM2 TPM4 TRIM29 TSHZ2 TXN UACA VIM WDR1 YBX1 ZBED2
9 | CancerCellState_Alveolar AGER CAPN8 CAV1 CAV2 CLIC5 CST6 CYP4B1 EMP2 FXYD3 LMO7 MYL12A MYL9 RARRES2 SCEL TNNC1 TRAM1
10 | CancerCellState_Basal ALDH3A1 ASPN ASS1 ATP1B3 COL17A1 COL18A1 CXCL14 DCN DST FBXO32 FTH1 GABRP GPNMB HOPX ITGB4 JMJD1C KRT14 KRT15 KRT5 NAV2 NDRG2 PDLIM1 SFRP1 SLITRK6 THBS2 TP53AIP1 TPT1 TXNIP UBA52 UQCRH VCAN VTCN1 ZFAND5
11 | CancerCellState_Squamous AKR1B10 AQP3 C10orf99 CA2 CALML3 CALML5 CD14 CDH1 CLDN7 CRABP2 DEFB1 DMKN DSC1 DSC2 DSG1 DSP FABP5 FGFBP1 GJB2 GRHL3 IGFL1 IVL KLC3 KLK10 KLK11 KRT1 KRT10 KRT16 KRT2 KRT6A KRT6B KRT6C KRTDAP LGALS7B LY6D LYPD3 MALL P2RY2 PKP1 PLA2G4E PRSS3 PVRL4 RAB25 RHOV S100A14 S100A7 S100A8 S100A9 SAA2 SBSN SERPINB13 SERPINB3 SERPINB4 SLPI SPINK5 SPRR1B SPRR2A SPRR2D SULT2B1 THBD TMEM45A TMPRSS4 TUBB2A ZNF750
12 | CancerCellState_Glandular AGR2 AQP5 BCAT1 C15orf48 CD47 CEACAM5 CEACAM6 CLDN10 CLDN18 CLU CP CREB3L1 CST2 CST4 CTSS CYP3A5 DHRS9 DMBT1 FMOD GPX2 IGFBP5 IL1R2 KIAA1324 KRT23 LCN2 LGALS4 LTF LYZ MAL2 MIA MMP7 MUC1 MUC16 MUC5AC MUC5B NAPSA NQO1 OLFM4 ONECUT2 PGC PHGR1 PIGR PLA2G2A PLAC8 PLAT PPP1R1B PSCA PTGES REG1A REG4 RNASE1 S100A4 S100P SCD SCGB1D2 SERPINA1 SERPINB1 SFTPD SPINK1 SPINT2 SQLE TCN1 TFF1 TFF2 TFF3 TM4SF4 TMEM176A TMEM176B TSPAN8 WFDC2
13 | CancerCellState_Ciliated AC007906.2 AGR3 ARMC3 C1orf194 C20orf85 C5orf49 C9orf116 C9orf24 CALM1 CAPS CAPSL CCDC146 CCDC170 CETN2 CFAP126 CFAP157 CFAP43 CSPP1 CTXN1 DNAAF1 DNAH12 DNALI1 DYNLL1 EFHC1 FAM183A FAM229B FOXJ1 LRRC23 LRRIQ1 MORN2 MS4A8 PIFO PPIL6 PSENEN ROPN1L RSPH1 SPATA18 TPPP3 UBXN10
14 | CancerCellState_AC AGT ALDOC APOE AQP4 BBOX1 CASQ1 CPVL CRYAB CSRP1 CYSTM1 DKK3 DOK5 EEPD1 EFEMP1 EZR GABRB1 GATSL3 GFAP GRAMD3 ID3 ID4 LAMP5 LCAT LPL MLC1 MT1X NTRK2 OLFM2 PLTP PMP22 PRLHR SPARCL1 SPOCK1 TBC1D10A VAMP5
15 | CancerCellState_OPC ASCL1 MAP3K1 MMP2 OLIG1 OLIG2 SEZ6L SOX8 WSCD1
16 | CancerCellState_NPC ARL4D CAMK2N1 CCNG2 CELF4 CELF5 DAAM1 DCX DLX1 DLX2 DLX5 DLX6 DLX6-AS1 GPC2 KIF5C KLHDC8A KLHL35 LBH MEIS2 MIAT NREP NSG1 PAK3 RAB3A RBFOX2 SOX11 STMN2 STMN4 SYT1 TAGLN3 TMSB15A
17 |
--------------------------------------------------------------------------------
/inst/extdata/GeneSets/TLS.gmt:
--------------------------------------------------------------------------------
1 | TLS AL928768.3 ATP2A3 BLK CCL19 CCR7 CD19 CD22 CD37 CD52 CD79A CD79B CXCL13 CXCR5 FCMR FCRLA IKZF3 IL16 LINC00926 LTB MS4A1 NIBAN3 POU2AF1 RAC2 RASGRP2 RIPOR2 SELL TCF7 TCL1A TNFRSF13C VPREB3
2 |
--------------------------------------------------------------------------------
/inst/extdata/Ref_Normal_LIHC.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Ref_Normal_LIHC.rda
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/filtered_feature_bc_matrix.h5:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/filtered_feature_bc_matrix.h5
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/filtered_feature_bc_matrix/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/filtered_feature_bc_matrix/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/filtered_feature_bc_matrix/barcodes.tsv.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/filtered_feature_bc_matrix/barcodes.tsv.gz
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/filtered_feature_bc_matrix/features.tsv.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/filtered_feature_bc_matrix/features.tsv.gz
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/filtered_feature_bc_matrix/matrix.mtx.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/filtered_feature_bc_matrix/matrix.mtx.gz
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/spatial/scalefactors_json.json:
--------------------------------------------------------------------------------
1 | {"spot_diameter_fullres": 177.4829519178534, "tissue_hires_scalef": 0.08250825, "fiducial_diameter_fullres": 286.7032300211478, "tissue_lowres_scalef": 0.024752475}
--------------------------------------------------------------------------------
/inst/extdata/Visium_BC/spatial/tissue_lowres_image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/Visium_BC/spatial/tissue_lowres_image.png
--------------------------------------------------------------------------------
/inst/extdata/cancerDictionary.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/cancerDictionary.rda
--------------------------------------------------------------------------------
/inst/extdata/combRef_0.5.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/combRef_0.5.rda
--------------------------------------------------------------------------------
/inst/extdata/hiresST_CRC/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/hiresST_CRC/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/hiresST_CRC/colors_vector.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/hiresST_CRC/colors_vector.rda
--------------------------------------------------------------------------------
/inst/extdata/hiresST_CRC/counts.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/hiresST_CRC/counts.rda
--------------------------------------------------------------------------------
/inst/extdata/hiresST_CRC/spotCoordinates.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/hiresST_CRC/spotCoordinates.rda
--------------------------------------------------------------------------------
/inst/extdata/oldST_PDAC/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/oldST_PDAC/.DS_Store
--------------------------------------------------------------------------------
/inst/extdata/oldST_PDAC/sc_PDAC.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/oldST_PDAC/sc_PDAC.rda
--------------------------------------------------------------------------------
/inst/extdata/oldST_PDAC/st_PDAC.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/inst/extdata/oldST_PDAC/st_PDAC.rda
--------------------------------------------------------------------------------
/man/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/man/.DS_Store
--------------------------------------------------------------------------------
/man/SpaCET-class.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \docType{class}
4 | \name{SpaCET-class}
5 | \alias{SpaCET-class}
6 | \title{Define the SpaCET object}
7 | \description{
8 | Define the SpaCET object
9 | }
10 | \section{Slots}{
11 |
12 | \describe{
13 | \item{\code{input}}{The input data}
14 |
15 | \item{\code{results}}{The results}
16 | }}
17 |
18 |
--------------------------------------------------------------------------------
/man/SpaCET.CCI.LRNetworkScore.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.CCI.LRNetworkScore}
4 | \alias{SpaCET.CCI.LRNetworkScore}
5 | \title{Ligand-Receptor interaction enrichment analysis}
6 | \usage{
7 | SpaCET.CCI.LRNetworkScore(SpaCET_obj, coreNo = 6)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{coreNo}{Core number in parallel computation.}
13 | }
14 | \value{
15 | A SpaCET object.
16 | }
17 | \description{
18 | Calculate the overall intensity of L-R interactions within ST spots.
19 | }
20 | \examples{
21 | SpaCET_obj <- SpaCET.CCI.LRNetworkScore(SpaCET_obj, coreNo=6)
22 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "LRNetworkScore", spatialFeatures=c("Network_Score","Network_Score_pv"))
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/man/SpaCET.CCI.cellTypePair.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.CCI.cellTypePair}
4 | \alias{SpaCET.CCI.cellTypePair}
5 | \title{Ligand-Receptor analysis for a co-localized cell-type pair}
6 | \usage{
7 | SpaCET.CCI.cellTypePair(SpaCET_obj, cellTypePair)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{cellTypePair}{A pair of cell-types.}
13 | }
14 | \value{
15 | A SpaCET object.
16 | }
17 | \description{
18 | Test the co-expression of ligands and receptors within the same ST spot for the co-localized cell-type pairs.
19 | }
20 | \examples{
21 | SpaCET_obj <- SpaCET.CCI.cellTypePair(SpaCET_obj, cellTypePair=c("CAF","Macrophage M2"))
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/man/SpaCET.CCI.colocalization.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.CCI.colocalization}
4 | \alias{SpaCET.CCI.colocalization}
5 | \title{Cell-cell colocalization analysis}
6 | \usage{
7 | SpaCET.CCI.colocalization(SpaCET_obj)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 | }
12 | \value{
13 | A SpaCET object.
14 | }
15 | \description{
16 | Calculate the cell-type pair colocalization by using Spearman correlation analysis.
17 | }
18 | \examples{
19 | SpaCET_obj <- SpaCET.CCI.colocalization(SpaCET_obj)
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/man/SpaCET.GeneSetScore.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{SpaCET.GeneSetScore}
4 | \alias{SpaCET.GeneSetScore}
5 | \title{Calculate gene set score for each spot}
6 | \usage{
7 | SpaCET.GeneSetScore(SpaCET_obj, GeneSets)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{GeneSets}{A string for in-house gene sets, or a list object for user-defined gene sets. See details.}
13 | }
14 | \value{
15 | A SpaCET object
16 | }
17 | \description{
18 | Calculate spots' gene set score from the in-house or user-defined gene sets.
19 | }
20 | \details{
21 | 1) Set `GeneSets` as "Hallmark", "CancerCellState", or "TLS" to use the in-house gene sets.
22 | "Hallmark": https://www.gsea-msigdb.org/gsea/msigdb/human/collections.jsp#H
23 |
24 | "CancerCellState": https://www.nature.com/articles/s41588-022-01141-9
25 |
26 | "TLS": https://www.researchsquare.com/article/rs-3921508
27 |
28 | 2) Set `GeneSets` as a list to use the user-defined gene sets. Each entry should be a vector of gene symbols.
29 |
30 | The function `ScoreSignatures_UCell` from `UCell` is used to calculate gene-set scores.
31 | https://bioconductor.org/packages/release/bioc/html/UCell.html.
32 | }
33 | \examples{
34 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets="Hallmark")
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/man/SpaCET.combine.interface.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.combine.interface}
4 | \alias{SpaCET.combine.interface}
5 | \title{Combine interaction spots to interface}
6 | \usage{
7 | SpaCET.combine.interface(SpaCET_obj, cellTypePair)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{cellTypePair}{A pair of cell types.}
13 | }
14 | \value{
15 | A SpaCET object.
16 | }
17 | \description{
18 | Demonstrate the spatial position of interaction spots at the tumor microenvironment.
19 | }
20 | \examples{
21 | SpaCET_obj <- SpaCET.combine.interface(SpaCET_obj,cellTypePair=c("CAF", "Macrophage M2"))
22 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "Interface", spatialFeature = "Interaction")
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/man/SpaCET.deconvolution.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/deconvolution.R
3 | \name{SpaCET.deconvolution}
4 | \alias{SpaCET.deconvolution}
5 | \title{Deconvolve tumor ST data set}
6 | \usage{
7 | SpaCET.deconvolution(
8 | SpaCET_obj,
9 | cancerType,
10 | adjacentNormal = FALSE,
11 | coreNo = 6
12 | )
13 | }
14 | \arguments{
15 | \item{SpaCET_obj}{A SpaCET object.}
16 |
17 | \item{cancerType}{Cancer type of the current tumor ST dataset.}
18 |
19 | \item{adjacentNormal}{Indicate whether your sample is normal tissue adjacent to the tumor. If TURE, SpaCET will skip the stage of malignant cell inference. Default: FALSE.}
20 |
21 | \item{coreNo}{Core number in parallel computation.}
22 | }
23 | \value{
24 | A SpaCET object.
25 | }
26 | \description{
27 | Estimate the cell fraction of cell lineages and sub lineages.
28 | }
29 | \examples{
30 | SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="BRCA", coreNo=6)
31 |
32 | }
33 |
--------------------------------------------------------------------------------
/man/SpaCET.deconvolution.malignant.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{SpaCET.deconvolution.malignant}
4 | \alias{SpaCET.deconvolution.malignant}
5 | \title{Deconvolve malignant cell fraction}
6 | \usage{
7 | SpaCET.deconvolution.malignant(
8 | SpaCET_obj,
9 | Malignant = "Malignant",
10 | malignantCutoff = 0.7,
11 | coreNo = 6
12 | )
13 | }
14 | \arguments{
15 | \item{SpaCET_obj}{A SpaCET object.}
16 |
17 | \item{Malignant}{Indicates the name of malignant cell type in the major lineage layer from the deconvolution results. Default: "Malignant".}
18 |
19 | \item{malignantCutoff}{Fraction cutoff for defining spots with high abundant malignant cells. Default: 0.7.}
20 |
21 | \item{coreNo}{Core number in parallel.}
22 | }
23 | \value{
24 | A SpaCET object
25 | }
26 | \description{
27 | Explore different malignant cell states in tumor ST dataset.
28 | }
29 | \examples{
30 | SpaCET_obj <- SpaCET.deconvolution.malignant(SpaCET_obj)
31 |
32 | }
33 |
--------------------------------------------------------------------------------
/man/SpaCET.deconvolution.malignant.customized.scRNAseq.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{SpaCET.deconvolution.malignant.customized.scRNAseq}
4 | \alias{SpaCET.deconvolution.malignant.customized.scRNAseq}
5 | \title{Deconvolve malignant fraction with customized scRNAseq data}
6 | \usage{
7 | SpaCET.deconvolution.malignant.customized.scRNAseq(
8 | SpaCET_obj,
9 | Malignant = "Malignant",
10 | sc_counts,
11 | sc_annotation,
12 | sc_lineageTree,
13 | sc_nCellEachLineage = 100,
14 | coreNo = 6
15 | )
16 | }
17 | \arguments{
18 | \item{SpaCET_obj}{A SpaCET object.}
19 |
20 | \item{Malignant}{Indicates the name of malignant cell type in the major lineage layer from the deconvolution results. Default: "Malignant".}
21 |
22 | \item{sc_counts}{Single cell count matrix with gene name (row) x cell ID (column).}
23 |
24 | \item{sc_annotation}{Single cell annotation matrix. This matrix should include two columns, i,e., cellID and cellType. Each row represents a single cell.}
25 |
26 | \item{sc_lineageTree}{Cell lineage tree. This should be organized by using a list, and the name of each element are major lineages while the value of elements are the corresponding sublineages. If a major lineage does not have any sublineages, the value of this major lineage should be itself.}
27 |
28 | \item{sc_nCellEachLineage}{Cell count each lineage. Default: 100. If a cell type is comprised of >100 cells, only 100 cells per cell identity are randomly selected to generate cell type reference.}
29 |
30 | \item{coreNo}{Core number in parallel.}
31 | }
32 | \value{
33 | A SpaCET object
34 | }
35 | \description{
36 | Explore different malignant cell states in tumor ST dataset.
37 | }
38 | \examples{
39 | SpaCET_obj <- SpaCET.deconvolution.malignant.customized.scRNAseq(SpaCET_obj, Malignant="Malignant", sc_counts, sc_annotation, sc_lineageTree, sc_nCellEachLineage=100, coreNo=6)
40 |
41 | }
42 |
--------------------------------------------------------------------------------
/man/SpaCET.deconvolution.matched.scRNAseq.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{SpaCET.deconvolution.matched.scRNAseq}
4 | \alias{SpaCET.deconvolution.matched.scRNAseq}
5 | \title{Deconvolve ST data set with matched scRNAseq data}
6 | \usage{
7 | SpaCET.deconvolution.matched.scRNAseq(
8 | SpaCET_obj,
9 | sc_includeMalignant = TRUE,
10 | cancerType,
11 | sc_counts,
12 | sc_annotation,
13 | sc_lineageTree,
14 | sc_nCellEachLineage = 100,
15 | coreNo = 6
16 | )
17 | }
18 | \arguments{
19 | \item{SpaCET_obj}{A SpaCET object.}
20 |
21 | \item{sc_includeMalignant}{Indicate whether the single cell data include malignant cells. If FALSE, please input a cancer type and then SpaCET will infer the malignant cell fraction based on its build-in reference.}
22 |
23 | \item{cancerType}{Cancer type of the current tumor ST sample.}
24 |
25 | \item{sc_counts}{Single cell count matrix with gene name (row) x cell ID (column).}
26 |
27 | \item{sc_annotation}{Single cell annotation matrix. This matrix should include two columns, i,e., cellID and cellType. Each row represents a single cell.}
28 |
29 | \item{sc_lineageTree}{Cell lineage tree. This should be organized by using a list, and the name of each element are major lineages while the value of elements are the corresponding sublineages. If a major lineage does not have any sublineages, the value of this major lineage should be itself.}
30 |
31 | \item{sc_nCellEachLineage}{Cell count each lineage. Default: 100. If a cell type is comprised of >100 cells, only 100 cells per cell identity are randomly selected to generate cell type reference.}
32 |
33 | \item{coreNo}{Core number.}
34 | }
35 | \value{
36 | A SpaCET object
37 | }
38 | \description{
39 | Estimate the fraction of cell lineage and sub lineage.
40 | }
41 | \examples{
42 | SpaCET_obj <- SpaCET.deconvolution.matched.scRNAseq(SpaCET_obj, sc_counts, sc_annotation, sc_lineageTree)
43 |
44 | }
45 |
--------------------------------------------------------------------------------
/man/SpaCET.distance.to.interface.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.distance.to.interface}
4 | \alias{SpaCET.distance.to.interface}
5 | \title{Distance to tumor border}
6 | \usage{
7 | SpaCET.distance.to.interface(
8 | SpaCET_obj,
9 | cellTypePair = c("CAF", "Macrophage M2"),
10 | nPermutation = 1000
11 | )
12 | }
13 | \arguments{
14 | \item{SpaCET_obj}{A SpaCET object.}
15 |
16 | \item{cellTypePair}{A pair of cell types.}
17 |
18 | \item{nPermutation}{Permutation number.}
19 | }
20 | \value{
21 | A ggplot object.
22 | }
23 | \description{
24 | Calculate the distance of cell-cell interactions to tumor-immune interface.
25 | }
26 | \examples{
27 | SpaCET.distance.to.interface(SpaCET_obj, cellTypePair=c("CAF", "Macrophage M2"))
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/man/SpaCET.identify.interface.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.identify.interface}
4 | \alias{SpaCET.identify.interface}
5 | \title{Identify tumor-stroma interface}
6 | \usage{
7 | SpaCET.identify.interface(
8 | SpaCET_obj,
9 | Malignant = "Malignant",
10 | MalignantCutoff = 0.5
11 | )
12 | }
13 | \arguments{
14 | \item{SpaCET_obj}{A SpaCET object.}
15 |
16 | \item{Malignant}{Indicates the name of malignant cell type in the major lineage layer from the deconvolution results. Default: "Malignant".}
17 |
18 | \item{MalignantCutoff}{Malignant cell fraction cutoff for tumor boundary. Default: 0.5.}
19 | }
20 | \value{
21 | A SpaCET object.
22 | }
23 | \description{
24 | Identify the spots at the tumor-stroma interface.
25 | }
26 | \examples{
27 | SpaCET_obj <- SpaCET.identify.interface(SpaCET_obj)
28 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "Interface")
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/man/SpaCET.quality.control.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \name{SpaCET.quality.control}
4 | \alias{SpaCET.quality.control}
5 | \title{Filter spatial spots and calculate the QC metrics}
6 | \usage{
7 | SpaCET.quality.control(SpaCET_obj, min.genes = 1)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{min.genes}{Minimum number of expressed genes. Default: 1.}
13 | }
14 | \value{
15 | A SpaCET object.
16 | }
17 | \description{
18 | Spots with less than `min.genes` expressed genes would be removed.
19 | }
20 | \examples{
21 | SpaCET_obj <- SpaCET.quality.control(SpaCET_obj)
22 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "QualityControl", spatialFeatures=c("UMI","Gene"))
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/man/SpaCET.visualize.cellTypePair.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.visualize.cellTypePair}
4 | \alias{SpaCET.visualize.cellTypePair}
5 | \title{Cell-type pair visualization}
6 | \usage{
7 | SpaCET.visualize.cellTypePair(SpaCET_obj, cellTypePair)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{cellTypePair}{A pair of cell types.}
13 | }
14 | \value{
15 | A ggplot object.
16 | }
17 | \description{
18 | Visualize the interaction analysis of a co-localized cell-type pair.
19 | }
20 | \examples{
21 | SpaCET.visualize.cellTypePair(SpaCET_obj, cellTypePair=c("CAF","Macrophage M2"))
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/man/SpaCET.visualize.colocalization.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/interaction.R
3 | \name{SpaCET.visualize.colocalization}
4 | \alias{SpaCET.visualize.colocalization}
5 | \title{Cell-cell colocalization visualization}
6 | \usage{
7 | SpaCET.visualize.colocalization(SpaCET_obj)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 | }
12 | \value{
13 | A ggplot object.
14 | }
15 | \description{
16 | Visualize the cell-type pair colocalization.
17 | }
18 | \examples{
19 | SpaCET.visualize.colocalization(SpaCET_obj)
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/man/SpaCET.visualize.spatialFeature.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/visualization.R
3 | \name{SpaCET.visualize.spatialFeature}
4 | \alias{SpaCET.visualize.spatialFeature}
5 | \title{Spatial feature visualization}
6 | \usage{
7 | SpaCET.visualize.spatialFeature(
8 | SpaCET_obj,
9 | spatialType,
10 | spatialFeatures = NULL,
11 | scaleTypeForGeneExpression = "LogTPM",
12 | sameScaleForFraction = FALSE,
13 | colors = NULL,
14 | pointSize = 1,
15 | pointAlpha = 1,
16 | nrow = 1,
17 | imageBg = TRUE,
18 | imageSize = "CompleteImage",
19 | legend.position = "right",
20 | interactive = FALSE
21 | )
22 | }
23 | \arguments{
24 | \item{SpaCET_obj}{A SpaCET object.}
25 |
26 | \item{spatialType}{Type of spatial features, i.e., "QualityControl", "GeneExpression", "CellFraction", "LRNetworkScore", "Interface", and "GeneSetScore". See ‘details’ for more information.}
27 |
28 | \item{spatialFeatures}{A vector of spatial features.}
29 |
30 | \item{scaleTypeForGeneExpression}{Scale type of gene expression, i.e., "RawCounts","LogRawCounts","LogTPM/10", and "LogTPM".}
31 |
32 | \item{sameScaleForFraction}{Indicate whether all cell types have the same scale for cell fraction.}
33 |
34 | \item{colors}{A vector of colors for spots.}
35 |
36 | \item{pointSize}{Size of spots.}
37 |
38 | \item{pointAlpha}{Alpha transparency scales of spots. Must lie between 0 and 1.}
39 |
40 | \item{nrow}{Row number of the combined panel for multiple spatial features.}
41 |
42 | \item{imageBg}{Logical: should the image be shown as background?}
43 |
44 | \item{imageSize}{Size of the image, i.e., "CompleteImage", "CaptureArea".}
45 |
46 | \item{legend.position}{The position of the legend. Set it as "none" if you want to remove the legend.}
47 |
48 | \item{interactive}{Logical: should the interactive app be activited?}
49 | }
50 | \value{
51 | A ggplot2 object.
52 | }
53 | \description{
54 | Visualize multiple types of spatial features in ST data.
55 | }
56 | \details{
57 | `SpaCET.visualize.spatialFeature` is able to plot multiple types of spatial features, including "QC", "GeneExp", "CellFraction", and "LRNetworkScore".
58 | "QualityControl" refers to quality control metrics. User can visualize the total counts of UMI and genes across all spots.
59 | "GeneExpr" is set to visualize the expression level of genes.
60 | "CellFraction" refers to the cell fraction of cell types.
61 | "LRNetworkScore" is selected to show the Ligand-Receptor network score. See `SpaCET.CCI.LRNetworkScore` for how to calculate it.
62 | }
63 | \examples{
64 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "QualityControl", spatialFeatures=c("UMI","Gene"))
65 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "GeneExpression", spatialFeatures=c("EPCAM","MS4A1"))
66 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "CellFraction", spatialFeatures=c("Malignant","Macrophage"))
67 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "CellFraction", spatialFeatures="All", pointSize = 0.1, nrow=5)
68 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "LRNetworkScore", spatialFeatures=c("Network_Score","Network_Score_pv"))
69 |
70 | }
71 |
--------------------------------------------------------------------------------
/man/addTo.Seurat.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \name{addTo.Seurat}
4 | \alias{addTo.Seurat}
5 | \title{Add SpaCET to Seurat}
6 | \usage{
7 | addTo.Seurat(SpaCET_obj, Seurat_obj)
8 | }
9 | \arguments{
10 | \item{SpaCET_obj}{A SpaCET object.}
11 |
12 | \item{Seurat_obj}{A Seurat object.}
13 | }
14 | \value{
15 | An Seurat object.
16 | }
17 | \description{
18 | Add deconvolution results from a SpaCET object to an Seurat object as a new assay.
19 | }
20 | \examples{
21 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
22 | Seurat_obj <- Seurat::Load10X_Spatial(data.dir = visiumPath)
23 | SpaCET_obj <- convert.Seurat(Seurat_obj)
24 | SpaCET_obj <- SpaCET.quality.control(SpaCET_obj)
25 | SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="BRCA", coreNo=6)
26 | Seurat_obj <- addTo.Seurat(SpaCET_obj, Seurat_obj)
27 | Seurat::DefaultAssay(Seurat_obj) <- "propMatFromSpaCET"
28 | Seurat::SpatialFeaturePlot(Seurat_obj, features = c("CAF", "Macrophage"))
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/man/convert.Seurat.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \name{convert.Seurat}
4 | \alias{convert.Seurat}
5 | \title{Convert Seurat to SpaCET}
6 | \usage{
7 | convert.Seurat(Seurat_obj)
8 | }
9 | \arguments{
10 | \item{Seurat_obj}{An Seurat object.}
11 | }
12 | \value{
13 | A SpaCET object.
14 | }
15 | \description{
16 | Convert an Seurat object to a SpaCET object.
17 | }
18 | \examples{
19 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
20 | Seurat_obj <- Seurat::Load10X_Spatial(data.dir = visiumPath)
21 | SpaCET_obj <- convert.Seurat(Seurat_obj)
22 | SpaCET_obj <- SpaCET.quality.control(SpaCET_obj)
23 | SpaCET.visualize.spatialFeature(SpaCET_obj, spatialType = "QualityControl", spatialFeatures=c("UMI","Gene"))
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/man/create.SpaCET.object.10X.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \name{create.SpaCET.object.10X}
4 | \alias{create.SpaCET.object.10X}
5 | \title{Create a SpaCET object from 10X Visium}
6 | \usage{
7 | create.SpaCET.object.10X(visiumPath)
8 | }
9 | \arguments{
10 | \item{visiumPath}{Path to the Space Ranger output folder. See ‘details’ for more information.}
11 | }
12 | \value{
13 | A SpaCET object.
14 | }
15 | \description{
16 | Read an ST dataset to create a SpaCET object.
17 | }
18 | \details{
19 | If users are analyzing an ST data set from 10X Visium platform, they only need to input "visiumPath".
20 | Please make sure that "visiumPath" points to the standard output folder of 10X Space Ranger,
21 | which has both (1) sequencing data, i.e., `filtered_feature_bc_matrix.h5` file or `filtered_feature_bc_matrix` folder,
22 |
23 | The "filtered_feature_bc_matrix" folder includes \cr
24 | "barcodes.tsv.gz": spot level barcodes; \cr
25 | "features.tsv.gz": list of genes; \cr
26 | "matrix.mtx.gz": (sparse) matrix of counts.
27 |
28 | and (2) image folder `spatial`.
29 |
30 | The "spatial" folder includes \cr
31 | “tissue_positions_list.csv” : barcodes and spatial information; \cr
32 | “tissue_lowres_image.png” : hematoxylin and eosin (H&E) image; \cr
33 | “scalefactors_json.json” : scaling factors for adjusting the coordinates.
34 | }
35 | \examples{
36 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
37 | SpaCET_obj <- create.SpaCET.object.10X(visiumPath = visiumPath)
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/man/create.SpaCET.object.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/utilities.R
3 | \name{create.SpaCET.object}
4 | \alias{create.SpaCET.object}
5 | \title{Create a SpaCET object}
6 | \usage{
7 | create.SpaCET.object(
8 | counts,
9 | spotCoordinates,
10 | metaData = NULL,
11 | imagePath = NA,
12 | platform
13 | )
14 | }
15 | \arguments{
16 | \item{counts}{Count matrix with gene name (row) x spot ID (column).}
17 |
18 | \item{spotCoordinates}{Spot coordinate matrix with spot ID (row) x coordinates (column). This matrix should include two columns, i,e., X and Y coordinates, respectively, which represent the position of spots in H&E image.}
19 |
20 | \item{imagePath}{Path to the H&E image file. Can be NA if it is not available.}
21 |
22 | \item{platform}{A character string indicating the platform, i.e., "Visium", "OldST", or "Slide-Seq". "OldST" is the early in situ capturing method from which "Visium" was developed.}
23 | }
24 | \value{
25 | A SpaCET object.
26 | }
27 | \description{
28 | Read an ST dataset to create a SpaCET object.
29 | }
30 | \details{
31 | To create a SpaCET object, user need to input four parameters, i.e., "counts", "spotCoordinates", "imagePath", and "platform".
32 | However, if analyzing the Visium data, it is more easy to use `create.SpaCET.object.10X` to read ST data.
33 | }
34 | \examples{
35 | SpaCET_obj <- create.SpaCET.object(counts, spotCoordinates, imagePath, platform)
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/man/figures/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/man/figures/.DS_Store
--------------------------------------------------------------------------------
/man/figures/sticker.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/man/figures/sticker.png
--------------------------------------------------------------------------------
/man/figures/workflow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/man/figures/workflow.png
--------------------------------------------------------------------------------
/man/read.gmt.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{read.gmt}
4 | \alias{read.gmt}
5 | \title{Read a gmt file}
6 | \usage{
7 | read.gmt(gmtPath)
8 | }
9 | \arguments{
10 | \item{gmtPath}{Path to a gmt file.}
11 | }
12 | \value{
13 | A gene set list
14 | }
15 | \description{
16 | Read a gmt file as a gene set list.
17 | }
18 | \examples{
19 | gmt <- read.gmt(gmtPath)
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/man/write.gmt.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/extensions.R
3 | \name{write.gmt}
4 | \alias{write.gmt}
5 | \title{Write a gmt file}
6 | \usage{
7 | write.gmt(gmt, gmtPath)
8 | }
9 | \arguments{
10 | \item{gmt}{A gene set list.}
11 |
12 | \item{gmtPath}{Path to a gmt file.}
13 | }
14 | \description{
15 | Write a gene set list as a gmt file.
16 | }
17 | \examples{
18 | write.gmt(gmt, gmtPath)
19 |
20 | }
21 |
--------------------------------------------------------------------------------
/vignettes/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/.DS_Store
--------------------------------------------------------------------------------
/vignettes/GeneSetScore.Rmd:
--------------------------------------------------------------------------------
1 | ---
2 | title: "Gene set score calculation"
3 | output: rmarkdown::html_vignette
4 | description: >
5 | Gene set score calculation.
6 | vignette: >
7 | %\VignetteIndexEntry{Gene set score calculation}
8 | %\VignetteEngine{knitr::rmarkdown}
9 | %\VignetteEncoding{UTF-8}
10 | ---
11 | ---
12 | output: github_document
13 | ---
14 |
15 |
16 | ```{r, include = FALSE}
17 | knitr::opts_chunk$set(
18 | collapse = TRUE,
19 | comment = "#>"
20 | )
21 | ```
22 |
23 | In this vignette, we will demonstrate how to use `SpaCET` to calculate and visualize spots' gene set score for the in-house or user-defined gene sets. The in-house gene sets include hallmarks, cancer cell states, and tertiary lymphoid structures (TLS).
24 |
25 | ## Create SpaCET object
26 |
27 | To read your ST data into R, user can create an SpaCET object by using `create.SpaCET.object` or `create.SpaCET.object.10X`. Specifically, if users are analyzing an ST dataset from 10x Visium, they only need to input "visiumPath" by using `create.SpaCET.object.10X`. Please make sure that "visiumPath" points to the standard output folders of 10x Space Ranger, which has both "filtered_feature_bc_matrix" and "spatial" folders.
28 |
29 | ``` r
30 | library(SpaCET)
31 |
32 | # set the path to the in-house breast cancer ST data. User can set the paths to their own data.
33 | visiumPath <- file.path(system.file(package = "SpaCET"), "extdata/Visium_BC")
34 |
35 | # load ST data to create an SpaCET object.
36 | SpaCET_obj <- create.SpaCET.object.10X(visiumPath = visiumPath)
37 |
38 | # calculate the QC metrics
39 | SpaCET_obj <- SpaCET.quality.control(SpaCET_obj)
40 |
41 | ```
42 |
43 | ## Calculate hallmark score
44 | The in-house 50 hallmark gene sets were collected from [MSigDB](https://www.gsea-msigdb.org/gsea/msigdb/human/collections.jsp#H){target="_blank"} and user just need to set `GeneSets` as "Hallmark". `SpaCET.GeneSetScore` will call `UCell` package to calculate gene set score. The results are stored in `SpaCET_obj@results$GeneSetScore` as a matrix.
45 |
46 | ``` r
47 | # run gene set calculation
48 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets="Hallmark")
49 |
50 | # show results
51 | SpaCET_obj@results$GeneSetScore[1:6,1:6]
52 |
53 | # show all gene sets
54 | rownames(SpaCET_obj@results$GeneSetScore)
55 |
56 | # visualize two gene sets
57 | SpaCET.visualize.spatialFeature(
58 | SpaCET_obj,
59 | spatialType = "GeneSetScore",
60 | spatialFeatures = c("HALLMARK_HYPOXIA","HALLMARK_TGF_BETA_SIGNALING")
61 | )
62 | ```
63 |
64 |
65 |
66 | ## Calculate cancer cell state score
67 | A recent [study](https://www.nature.com/articles/s41588-022-01141-9){target="_blank"} identifies a catalog of gene modules whose expression defines 16 recurrent cancer cell states through a pan-caner single-cell RNA-sequencing analysis. In order to use them, user just need to set `GeneSets` as "CancerCellState".
68 |
69 | ``` r
70 | # run gene set calculation
71 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets="CancerCellState")
72 |
73 | # show all gene sets
74 | rownames(SpaCET_obj@results$GeneSetScore)
75 |
76 | # visualize two gene sets
77 | SpaCET.visualize.spatialFeature(
78 | SpaCET_obj,
79 | spatialType = "GeneSetScore",
80 | spatialFeatures = c("CancerCellState_Cycle","CancerCellState_cEMT")
81 | )
82 | ```
83 |
84 |
85 | ## Calculate TLS score
86 | User just need to set `GeneSets` as "TLS" to calculate tertiary lymphoid structure score. We collected a 30-gene TLS signature from this [study](https://www.nature.com/articles/s41467-024-54145-w){target="_blank"}.
87 |
88 | ``` r
89 | # run gene set calculation
90 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets="TLS")
91 |
92 | # visualize TLS
93 | SpaCET.visualize.spatialFeature(
94 | SpaCET_obj,
95 | spatialType = "GeneSetScore",
96 | spatialFeatures = c("TLS")
97 | )
98 | ```
99 |
100 |
101 |
102 | ## Calculate other gene sets' score
103 | There are two methods to build customized gene sets. 1) Generate a list to define some simple gene sets (e.g., T cell and Myeloid signatures). 2) Download a gmt file from [MSigDB](https://www.gsea-msigdb.org/gsea/msigdb/human/collections.jsp){target="_blank"} (e.g., GO Ontology), and then use `read.gmt` to read this file as a list.
104 |
105 | ``` r
106 | # 1)
107 | gmt1 <- list(
108 | Tcell = c("CD2","CD3E","CD3D"),
109 | Myeloid = c("SPI1","FCER1G","CSF1R")
110 | )
111 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets = gmt1)
112 |
113 | # 2)
114 | gmt2 <- read.gmt("Path_to_gmt_file")
115 | SpaCET_obj <- SpaCET.GeneSetScore(SpaCET_obj, GeneSets = gmt2)
116 |
117 | ```
118 |
--------------------------------------------------------------------------------
/vignettes/hiresST_CRC.Rmd:
--------------------------------------------------------------------------------
1 | ---
2 | title: "Application to high resolution spatial transcriptomics data"
3 | output: rmarkdown::html_vignette
4 | description: >
5 | Application to high resolution spatial transcriptomics data.
6 | vignette: >
7 | %\VignetteIndexEntry{Application to high resolution spatial transcriptomics data}
8 | %\VignetteEngine{knitr::rmarkdown}
9 | %\VignetteEncoding{UTF-8}
10 | ---
11 | ---
12 | output: github_document
13 | ---
14 |
15 |
16 | ```{r, include = FALSE}
17 | knitr::opts_chunk$set(
18 | collapse = TRUE,
19 | comment = "#>"
20 | )
21 | ```
22 |
23 | This tutorial demonstrates how to apply SpaCET to a colorectal cancer Slide-seq dataset from [Zhao et al, 2021](https://www.nature.com/articles/s41586-021-04217-4){target="_blank"}. Each bead is 10 µm in diameter covering 1-2 cells. Before running the tutorial, make sure that the SpaCET package and its dependencies have been installed.
24 |
25 | ## Create SpaCET object
26 |
27 | User need `create.SpaCET.object` to create a SpaCET object by preparing four types of input data referring to a tumor ST sample.
28 |
29 | 1) spatial transcriptomics count data. The spatial transcriptomics count data must be in the format of matrix with gene name (row) x spot ID (column).
30 | 2) spatial location information. The spot coordinates should be in the format of matrix with spot ID (row) x coordinates (column). This 1st and 2nd columns represent X and Y coordinates, respectively.
31 | 3) path to the H&E image file. The image path can be NA if unavailable.
32 | 4) platform.
33 |
34 | ``` r
35 | library(SpaCET)
36 |
37 | hiresST_Path <- system.file("extdata", 'hiresST_CRC', package = 'SpaCET')
38 |
39 | # load count matrix
40 | load(paste0(hiresST_Path,"/counts.rda"))
41 |
42 | # show count matrix
43 | counts[1:6,1:3]
44 |
45 | ## 6 x 3 sparse Matrix of class "dgCMatrix"
46 | ## 2364.115x3072.225 3484.52x1734.005 2279.745x2951.975
47 | ## A1BG . . .
48 | ## A1CF . 1 2
49 | ## A2M . . .
50 | ## A2ML1 . . .
51 | ## A3GALT2 . . .
52 | ## A4GALT . . .
53 |
54 | # load count matrix
55 | load(paste0(hiresST_Path,"/spotCoordinates.rda"))
56 |
57 | # show count matrix
58 | head(spotCoordinates)
59 |
60 | ## X Y
61 | ## 2364.115x3072.225 2364.115 3072.225
62 | ## 3484.52x1734.005 3484.520 1734.005
63 | ## 2279.745x2951.975 2279.745 2951.975
64 | ## 3061.825x1556.49 3061.825 1556.490
65 | ## 2274.22x2982.525 2274.220 2982.525
66 | ## 2986.945x1603.68 2986.945 1603.680
67 |
68 | # create a SpaCET object.
69 | SpaCET_obj <- create.SpaCET.object(
70 | counts=counts,
71 | spotCoordinates=spotCoordinates,
72 | imagePath=NA,
73 | platform = "SlideSeq"
74 | )
75 |
76 | # show this object.
77 | str(SpaCET_obj)
78 |
79 | ```
80 |
81 | ## Deconvolve ST data
82 |
83 | We use the in-house reference to deconvolve this ST sample.
84 |
85 | ``` r
86 | # deconvolve ST data
87 | SpaCET_obj <- SpaCET.deconvolution(SpaCET_obj, cancerType="CRC", coreNo=6)
88 | # Since Windows does not support parallel computation, please set coreNo=1 for Windows OS.
89 |
90 | # show the ST deconvolution results
91 | SpaCET_obj@results$deconvolution$propMat[1:13,1:3]
92 |
93 | ## 2364.115x3072.225 3484.52x1734.005 2279.745x2951.975
94 | ## Malignant 1 1 1
95 | ## CAF 0 0 0
96 | ## Endothelial 0 0 0
97 | ## Plasma 0 0 0
98 | ## B cell 0 0 0
99 | ## T CD4 0 0 0
100 | ## T CD8 0 0 0
101 | ## NK 0 0 0
102 | ## cDC 0 0 0
103 | ## pDC 0 0 0
104 | ## Macrophage 0 0 0
105 | ## Mast 0 0 0
106 | ## Neutrophil 0 0 0
107 | ```
108 |
109 | ## Visualize the cell type proportion
110 |
111 | We provide `SpaCET.visualize.spatialFeature` to present the spatial distribution of cell types. `spatialFeatures` could be a vector of cell types. If user would like to visualize multiple cell types in a single panel, you can assign a list to `spatialFeatures`. For example, combine CAF and endothelial cell types into stromal cell.
112 |
113 | ``` r
114 | # show the spatial distribution of malignant cells and macrophages.
115 | SpaCET.visualize.spatialFeature(
116 | SpaCET_obj,
117 | spatialType = "CellFraction",
118 | spatialFeatures = list(Malignant=c("Malignant"),Stromal=c("CAF","Endothelial")),
119 | sameScaleForFraction = TRUE,
120 | pointSize = 0.6
121 | )
122 | ```
123 |
124 |
125 | User can check the most abundant cell type in each bead by setting `spatialType` as "MostAbundantCellType". `spatialFeatures` could be "MajorLineage" or "SubLineage".
126 |
127 | ``` r
128 | # load the color for cell types
129 | load(paste0(hiresST_Path,"/colors_vector.rda"))
130 |
131 | # show colors
132 | head(colors_vector)
133 |
134 | ## Malignant CAF Endothelial Unidentifiable B cell cDC
135 | ## "#f3c300" "#be0032" "#0067a5" "#e25822" "#008856" "#782AB6"
136 |
137 | # show the spatial distribution of all cell types.
138 | SpaCET.visualize.spatialFeature(
139 | SpaCET_obj,
140 | spatialType = "MostAbundantCellType",
141 | spatialFeatures = "MajorLineage",
142 | colors = colors_vector,
143 | pointSize = 0.6
144 | )
145 | ```
146 |
147 |
--------------------------------------------------------------------------------
/vignettes/img/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/.DS_Store
--------------------------------------------------------------------------------
/vignettes/img/CAF-M2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/CAF-M2.png
--------------------------------------------------------------------------------
/vignettes/img/CCC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/CCC.png
--------------------------------------------------------------------------------
/vignettes/img/GS1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/GS1.png
--------------------------------------------------------------------------------
/vignettes/img/GS2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/GS2.png
--------------------------------------------------------------------------------
/vignettes/img/GS3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/GS3.png
--------------------------------------------------------------------------------
/vignettes/img/LRNetworkScore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/LRNetworkScore.png
--------------------------------------------------------------------------------
/vignettes/img/PDAC_CCC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/PDAC_CCC.png
--------------------------------------------------------------------------------
/vignettes/img/PDAC_expr.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/PDAC_expr.png
--------------------------------------------------------------------------------
/vignettes/img/PDAC_prop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/PDAC_prop.png
--------------------------------------------------------------------------------
/vignettes/img/QC.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/QC.png
--------------------------------------------------------------------------------
/vignettes/img/cancerCellState.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/cancerCellState.png
--------------------------------------------------------------------------------
/vignettes/img/cancerDictionary.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/cancerDictionary.png
--------------------------------------------------------------------------------
/vignettes/img/cancerInterface1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/cancerInterface1.png
--------------------------------------------------------------------------------
/vignettes/img/cancerInterface2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/cancerInterface2.png
--------------------------------------------------------------------------------
/vignettes/img/cancerInterface3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/cancerInterface3.png
--------------------------------------------------------------------------------
/vignettes/img/slideseq_anno.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/slideseq_anno.png
--------------------------------------------------------------------------------
/vignettes/img/slideseq_prop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/slideseq_prop.png
--------------------------------------------------------------------------------
/vignettes/img/visualizeDeconvolution.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/visualizeDeconvolution.png
--------------------------------------------------------------------------------
/vignettes/img/visualizeDeconvolution2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/visualizeDeconvolution2.png
--------------------------------------------------------------------------------
/vignettes/img/visualizeDeconvolution3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/data2intelligence/SpaCET/94235137b1bc40377caeca6f8305bfd31a0844ff/vignettes/img/visualizeDeconvolution3.png
--------------------------------------------------------------------------------
/vignettes/oldST_PDAC.Rmd:
--------------------------------------------------------------------------------
1 | ---
2 | title: "Deconvolution with a matched scRNA-seq data set"
3 | output: rmarkdown::html_vignette
4 | description: >
5 | Deconvolution with matched scRNA-seq data set.
6 | vignette: >
7 | %\VignetteIndexEntry{Deconvolution with a matched scRNA-seq data set}
8 | %\VignetteEngine{knitr::rmarkdown}
9 | %\VignetteEncoding{UTF-8}
10 | ---
11 | ---
12 | output: github_document
13 | ---
14 |
15 |
16 | ```{r, include = FALSE}
17 | knitr::opts_chunk$set(
18 | collapse = TRUE,
19 | comment = "#>"
20 | )
21 | ```
22 |
23 | Since most tumor spatial transcriptomics (ST) data do not have matched scRNA-seq data from the same sample, SpaCET does not require malignant, stromal and immune cell reference. However, SpaCET can still accept a customized reference to carry out cell type deconvolution. This tutorial demonstrates how to run SpaCET with a matched scRNA-seq dataset by using a pancreatic ductal adenocarcinoma (PDAC) ST data set from [Moncada et al, 2020](https://www.nature.com/articles/s41587-019-0392-8){target="_blank"}. Each spot is 100 µm in diameter.
24 |
25 | ## Create SpaCET object
26 | To read your ST data into R, user can create a SpaCET object by using `create.SpaCET.object` or `create.SpaCET.object.10X`. Specifically, if users are analyzing an ST dataset from 10x Visium, they only need to input "visiumPath" by using `create.SpaCET.object.10X`. Please make sure that "visiumPath" points to the standard output folders of 10x SpaCET Ranger, which has both "filtered_feature_bc_matrix" and "spatial" folders.
27 |
28 | Here, since the PDAC ST data set was generated from the original ST technology, user need `create.SpaCET.object` to create a SpaCET object by preparing four types of input data referring to a tumor ST sample.
29 |
30 | 1) spatial transcriptomics count data. The spatial transcriptomics count data must be in the format of matrix with gene name (row) x spot ID (column).
31 | 2) spatial location information. The spot coordinates should be in the format of matrix with spot ID (row) x coordinates (column). This 1st and 2nd columns represent X and Y coordinates, respectively.
32 | 3) path to the H&E image file. The image path can be NA if unavailable.
33 | 4) platform.
34 |
35 | ``` r
36 | library(SpaCET)
37 |
38 | oldST_Path <- system.file("extdata", 'oldST_PDAC', package = 'SpaCET')
39 | load(paste0(oldST_Path,"/st_PDAC.rda"))
40 |
41 | # show count matrix
42 | counts[1:6,1:5]
43 |
44 | ## 10x10 10x13 10x14 10x15 10x16
45 | ## A1CF 0 0 0 0 0
46 | ## A2M 13 0 4 0 0
47 | ## A4GALT 1 0 0 0 0
48 | ## A4GNT 0 0 1 0 0
49 | ## AAAS 0 0 0 0 0
50 | ## AACS 0 0 0 0 0
51 |
52 | # show coordinate matrix
53 | spotCoordinates[1:5,]
54 |
55 | ## X Y
56 | ## 10x10 10 10
57 | ## 10x13 10 13
58 | ## 10x14 10 14
59 | ## 10x15 10 15
60 | ## 10x16 10 16
61 |
62 | # load ST data to create a SpaCET object.
63 | SpaCET_obj <- create.SpaCET.object(
64 | counts=counts,
65 | spotCoordinates=spotCoordinates,
66 | imagePath=NA,
67 | platform = "oldST"
68 | )
69 |
70 | # show this object.
71 | str(SpaCET_obj)
72 |
73 | ```
74 |
75 | ## Deconvolve cell lineage
76 | We provide `SpaCET.deconvolution.matched.scRNAseq` to deconvolve a SpaCET object with a customized scRNA-seq data. User need to prepare three types of input data referring to the matched scRNA-seq dataset.
77 |
78 | 1) single cell RNA-seq (scRNA-seq) count data. The scRNA-seq count data must be in the format of matrix with gene name (row) x cell ID (column).
79 | 2) cell annotation information. This matrix should include two columns, i,e., cellID and cellType. Each row represents a single cell. The name of row should be same as the column cellID.
80 | 3) Hierarchical tree of cell types. This should be organized by using a list, and the name of each element are major lineages while the value of elements are the corresponding sublineages. If a major lineage does not have any sublineages, the value of this major lineage should be itself.
81 |
82 | ``` r
83 | # load sc data
84 | oldST_Path <- system.file("extdata", 'oldST_PDAC', package = 'SpaCET')
85 | load(paste0(oldST_Path,"/sc_PDAC.rda"))
86 |
87 | # show count matrix
88 | sc_counts[1:6,1:5]
89 |
90 | ## c1 c2 c3 c4 c5
91 | ## A1BG 0 0 0 0 0
92 | ## A1CF 0 0 0 1 0
93 | ## A2M 0 0 0 0 0
94 | ## A2ML1 0 0 0 0 0
95 | ## A3GALT2 0 0 0 0 0
96 | ## A4GALT 0 0 0 0 0
97 |
98 | # show cell annotation matrix
99 | sc_annotation[1:6,]
100 |
101 | ## cellID bio_celltype
102 | ## c1 "c1" "Acinar cells"
103 | ## c2 "c2" "Ductal - terminal ductal like"
104 | ## c3 "c3" "Ductal - terminal ductal like"
105 | ## c4 "c4" "Ductal - CRISP3 high/centroacinar like"
106 | ## c5 "c5" "Cancer clone A"
107 | ## c6 "c6" "Cancer clone A"
108 |
109 | # show cell type lineage tree
110 | head(sc_lineageTree)
111 |
112 | ## $Cancer
113 | ## [1] "Cancer clone A" "Cancer clone B"
114 | ##
115 | ## $Ductal
116 | ## [1] "Ductal - APOL1 high/hypoxic" "Ductal - CRISP3 high/centroacinar like"
117 | ## [3] "Ductal - MHC Class II" "Ductal - terminal ductal like"
118 | ##
119 | ## $Macrophage
120 | ## [1] "Macrophages A" "Macrophages B"
121 | ##
122 | ## $mDC
123 | ## [1] "mDCs A" "mDCs B"
124 | ##
125 | ## $`Acinar cells`
126 | ## [1] "Acinar cells"
127 | ##
128 | ## $`Endocrine cells`
129 | ## [1] "Endocrine cells"
130 | ```
131 |
132 | Then, user can run `SpaCET.deconvolution.matched.scRNAseq` to carry out cell type deconvolution.
133 |
134 | ``` r
135 | SpaCET_obj <- SpaCET.deconvolution.matched.scRNAseq(
136 | SpaCET_obj,
137 | sc_counts=sc_counts,
138 | sc_annotation=sc_annotation,
139 | sc_lineageTree=sc_lineageTree,
140 | coreNo=6
141 | )
142 |
143 | SpaCET.visualize.spatialFeature(
144 | SpaCET_obj,
145 | spatialType = "CellFraction",
146 | spatialFeatures = c("Cancer clone A","Cancer clone B","Acinar cells","Ductal - CRISP3 high/centroacinar like"),
147 | nrow=2
148 | )
149 | ```
150 |
151 |
152 |
153 | User can use the following code to visualize the marker gene expression level and verify the cell type deconvolution.
154 |
155 | ``` r
156 | # Markers for cancer clone A and B, acinar cell, and centroacinar like ductal cell
157 | SpaCET.visualize.spatialFeature(
158 | SpaCET_obj,
159 | spatialType = "GeneExpression",
160 | spatialFeatures = c("TM4SF1","S100A4","PRSS1","CRISP3"),
161 | nrow=2
162 | )
163 | ```
164 |
165 |
166 |
167 |
168 | ## Extand this function module
169 | Although our tutorials focus on analyzing ST data from tumor samples, in principle, SpaCET can be applied to any ST datasets with matched scRNA-seq data.
170 |
--------------------------------------------------------------------------------