Skip to main content

Identifying multiscale tissue domains for spatial transcriptomic data using persistent homology.

Project description

PHD-MS: Persistent Homology for Domains at Multiple Scales

Multiscale domain identification for spatial transcriptomic data.

Installation

Simply install with pip:

pip install phd_ms

Or install from source by downloading, cd to this directory, using:

pip install .

Usage/Examples

Detailed jupyter notebook tutorials are available in the examples folder. Or simply download the file titled 'point_and_click.py' and run the file to use our clickable graphical interface. When using the point_and_click.py interface, update the directory where your data is stored by changing this line:

DATA = '/home/pbeamer/Documents/graphst/visium_hne_graphst'

Here we'll show a simple example with Visium DLPFC data, using default parameters. First, import necessary components.

import phd-ms
import scanpy

Preprocessing steps here (note that we assume a spatially-aware embedding has already been computed for your data):

INPUT_FILE= '/home/pbeamer/Documents/graphst/adata_151673
phd_ms.tl.preprocess_leiden(INPUT_FILE,output_file=INPUT_FILE)

Compute persistent homology and plot 10 most prominent multiscale domains:

cluster_complex,clusterings= phd_ms.tl.cluster_filtration(adata)
phd_ms.tl.map_multiscale(adata.obsm['spatial'],cluster_complex,clusterings,num_domains=10)

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

phd_ms-1.1.tar.gz (12.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

phd_ms-1.1-py3-none-any.whl (13.0 kB view details)

Uploaded Python 3

File details

Details for the file phd_ms-1.1.tar.gz.

File metadata

  • Download URL: phd_ms-1.1.tar.gz
  • Upload date:
  • Size: 12.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for phd_ms-1.1.tar.gz
Algorithm Hash digest
SHA256 3739ff1ba712a3ed79c962d409ef24fab82c5f5312a736de2a6c09ee4f1ad1b6
MD5 50c1711076d6fccdec76e38d776cf4d2
BLAKE2b-256 b7d887ca423690fab692ac0ebd64e58f654660c8fd5b3ad00b9ccffc57645404

See more details on using hashes here.

File details

Details for the file phd_ms-1.1-py3-none-any.whl.

File metadata

  • Download URL: phd_ms-1.1-py3-none-any.whl
  • Upload date:
  • Size: 13.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for phd_ms-1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 25ca0baeed074438e69db34860818ba457cdd97b1fb8b385f101c29d788a6be4
MD5 fc52b4bf022a48a34befb076c1e647f1
BLAKE2b-256 247e8a80cc7fb67716e028128c1fe12b945dc2986561602a4cdf7be047b63607

See more details on using hashes here.

Supported by

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