This repository provides an API to fetch and analyze cell atlas data on various human diseases. For the time being, the API uses data from Cellxgene Census. Single cell omic data is compressed into h5 files using scquill.
NOTE
Compared to Cellxgene itself, this API is designed to be much faster and closer to typical biomedical questions.
Currently implemented:
- Analyze differential cell type abundance across disease states, sexes, and developmental stage.
- Analyze differential gene expression for all cell types or specific cell types in disease contexts.
- Fetch metadata related to diseases, including datasets, organs, and conditions.
- Retrieve average gene expression for specific genes across disease states.
- Identify top differentially expressed genes in disease-related contexts (e.g., kidney diseases).
Tutorial and reference documentation is available at https://cell-atlas-approximations-disease-api.readthedocs.io/en/latest/.
REST
The REST interface is language-agnostic and can be queried using any HTTP request handler, e.g. in JavaScript:
(async () => {
let response = await fetch("https://api-disease.atlasapprox.org/v1/metadata?disease=covid&cell_type=alveolar type 2");
if (response.ok) {
let data = await response.json();
console.log(data);
}
})();
Python
The Python interface uses a central API
class. Its methods implement the REST endpoints:
import atlasapprox_disease
api = atlasapprox_disease.API()
print(api.metadata())
print(api.average(disease="covid", features="IGHG1,CXCL13,S100A8"))