Skip to main content

SpatialDM: Spatial co-expression Detected by bivariate Moran

Project description

About

Installation

SpatialDM is available through PyPI. To install, type the following command line and add -U for updates:

pip install -U spatialdm

Alternatively, you can install from this GitHub repository for latest (often development) version by the following command line:

pip install -U git+https://github.com/leeyoyohku/SpatialDM

Installation time: < 1 min

Quick example

Using the build-in melanoma dataset as an example, the following Python script will compute the p-value indicating whether a certain Ligand-Receptor is spatially co-expressed.

import spatialdm as sdm
adata = sdm.datasets.melanoma()
my_sample = sdm.SpatialDM(X=adata.X, spatialcoord=adata.obsm['spatial'])
my_sample.extract_lr(species='human', min_cell=3)
my_sample.weight_matrix(l=1.2, cutoff=0.2, single_cell=False)
my_sample.spatialdm_global(1000, select_num=None, method='permutation')
sdm.pl.volcano(my_sample)

Detailed Manual

The full manual is at https://spatialdm.readthedocs.io

References

A BioRxiv preprint will be online soon.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

SpatialDM-0.0.2.linux-x86_64.tar.gz (33.4 kB view hashes)

Uploaded Source

Built Distributions

SpatialDM-0.0.2-py3-none-any.whl (21.2 kB view hashes)

Uploaded Python 3

SpatialDM-0.0.2-py2-none-any.whl (27.8 kB view hashes)

Uploaded Python 2

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page