-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
* update docs * Editorial changes * Editorial changes * Add docs * Render R doc-site * Make doc site clearer * Update api/r/cellxgene.census/README.md Co-authored-by: Andrew Tolopko <[email protected]> * Update api/r/cellxgene.census/README.md Co-authored-by: Andrew Tolopko <[email protected]> * Update api/r/cellxgene.census/README.md Co-authored-by: Andrew Tolopko <[email protected]> * Update docs/cellxgene_census_docsite_quick_start.md Co-authored-by: Andrew Tolopko <[email protected]> * Replace '=' with '<-' * Update install instructions * Fix installation instructions * Update installation instructions, and R version --------- Co-authored-by: Andrew Tolopko <[email protected]>
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
Package: cellxgene.census | ||
Title: CZ CELLxGENE Discover Cell Census | ||
Version: 0.0.0.9000 | ||
Version: 0.0.9.9 | ||
Authors@R: | ||
person("Chan Zuckerberg Initiative", email = "[email protected]", | ||
role = c("aut", "cre", "cph", "fnd")) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,90 @@ | ||
|
||
# CZ CELLxGENE Discover Census | ||
# R package of CZ CELLxGENE Discover Census | ||
|
||
<!-- badges: start --> | ||
<!-- badges: end --> | ||
|
||
This is the documentation for the R package `cellxgene.census` which is part of CZ CELLxGENE Discover Census. For full details on Census data and capabilities please go to the [main Census site](https://chanzuckerberg.github.io/cellxgene-census/). | ||
|
||
The `cellxgene.census` package provides an API to facilitate the use of the CZ CELLxGENE Discover Census. For more information about the API and the project visit the [chanzuckerberg/cellxgene-census GitHub repo](https://github.com/chanzuckerberg/cellxgene-census/). | ||
`cellxgene.census` provides an API to efficiently access the cloud-hosted Census single-cell data from R. In just a few seconds users can access any slice of Census data using cell or gene filters across hundreds of single-cell datasets. | ||
|
||
**Status**: Pre-release, under rapid development. Expect API changes. | ||
|
||
Also see the [Python API](https://cellxgene-census.readthedocs.io/). | ||
Census data can be fetched in an iterative fashion for bigger-than-memory slices of data, or quickly exported to basic R structures, as well as `Seurat` or `SingleCellExperiment` objects for downstream analysis. | ||
|
||
## Installation | ||
|
||
You can install the development version of `cellxgene.census` from [GitHub](https://github.com/) with: | ||
From an R session, first install `tiledb` from R-Universe, the latest release in CRAN is not yet available. | ||
|
||
If installing from Ubuntu, you may need to install the following libraries via `apt install`: `libxml2-dev` `libssl-dev` `libcurl4-openssl-dev`. | ||
|
||
If installing from MacOS, you will need to install the [developer tools `Xcode`](https://apps.apple.com/us/app/xcode/id497799835?mt=12). | ||
|
||
``` r | ||
# install.packages("devtools") | ||
devtools::install_github("chanzuckerberg/cellxgene-census/api/r/cellxgene.census") | ||
print(cellxgene.census::open_soma()) | ||
```r | ||
install.packages( | ||
"tiledb", | ||
version = "0.20.3", | ||
repos=c('https://tiledb-inc.r-universe.dev','https://cloud.r-project.org') | ||
) | ||
``` | ||
|
||
(minimal apt dependencies: r-base cmake git) | ||
Then install `cellxgene.census` from R-Universe. | ||
|
||
```r | ||
install.packages( | ||
"cellxgene.census", | ||
repos=c('https://chanzuckerberg.r-universe.dev', 'https://cloud.r-project.org') | ||
) | ||
``` | ||
|
||
## Usage | ||
|
||
Check out the vignettes in the "Articles" section of the navigation bar on this site. We highly recommend the following vignettes as a starting point: | ||
|
||
* [Querying and fetching the single-cell data and cell/gene metadata](./articles/census_query_extract.html) | ||
* [Learning about the CZ CELLxGENE Discover Census](./articles/comp_bio_census_info.html) | ||
|
||
You can also check out out the [quick start guide](https://chanzuckerberg.github.io/cellxgene-census/cellxgene_census_docsite_quick_start.html) in the main Census site. | ||
|
||
|
||
### Example `Seurat` and `SingleCellExperiment` query | ||
|
||
The following creates a `Seurat` object on-demand with all sympathetic neurons in Census and filtering only for the genes `ENSG00000161798`, `ENSG00000188229`. | ||
|
||
```r | ||
library("cellxgene.census") | ||
library("Seurat") | ||
|
||
census <- open_soma() | ||
|
||
organism <- "Homo sapiens" | ||
gene_filter <- "feature_id %in% c('ENSG00000107317', 'ENSG00000106034')" | ||
cell_filter <- "cell_type == 'sympathetic neuron'" | ||
cell_columns <- c("assay", "cell_type", "tissue", "tissue_general", "suspension_type", "disease") | ||
|
||
seurat_obj <- get_seurat( | ||
census = census, | ||
organism = organism, | ||
var_value_filter = gene_filter, | ||
obs_value_filter = cell_filter, | ||
obs_column_names = cell_columns | ||
) | ||
``` | ||
|
||
## Example | ||
And the following retrieves the same data as a `SingleCellExperiment` object. | ||
|
||
This is a basic example which shows you how to solve a common problem: | ||
```r | ||
library("SingleCellExperiment") | ||
|
||
``` r | ||
library(cellxgene.census) | ||
## basic example code | ||
sce_obj <- get_single_cell_experiment( | ||
census = census, | ||
organism = organism, | ||
var_value_filter = gene_filter, | ||
obs_value_filter = cell_filter, | ||
obs_column_names = cell_columns | ||
) | ||
``` | ||
|
||
## For More Help | ||
|
||
For more help, please file a issue on the repo, or contact us at <soma@chanzuckerberg.com> | ||
For more help, please go visit the [main Census site](https://chanzuckerberg.github.io/cellxgene-census/). | ||
|
||
If you believe you have found a security issue, we would appreciate notification. Please send email to <[email protected]>. | ||
If you believe you have found a security issue, we would appreciate notification. Please send an email to <[email protected]>. |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.