Skip to main content

Core foundation for Ji Universe

Project description

SpatioloJI

core foundation for Ji Universe

Ji Universe Logo

SpatioloJI is a comprehensive Python library for analyzing spatial transcriptomics data. It provides a robust framework for managing, visualizing, and performing advanced spatial statistics on multi-FOV (Field of View) spatial transcriptomics datasets.

Overview

SpatioloJI offers an extensive suite of tools and functionalities specifically designed to address the challenges in spatial transcriptomics data analysis:

  • Data Management: Organize cell polygons, gene expression, metadata, and images across multiple FOVs
  • Quality Control: Comprehensive QC pipeline for filtering cells and genes
  • Spatial Visualization: Advanced visualization tools for displaying cells, gene expression, and spatial relationships
  • Spatial Statistics: Methods for detecting spatial patterns, correlations, and organization of cells and gene expression
  • Network Analysis: Tools for building and analyzing cell interaction networks

Main Components

The library consists of three main components:

  1. Quality Control (Spatioloji_qc Class): Tools for quality control and data preprocessing
  2. Spatioloji Class (Spatial_Object.py): Core data structure for managing filtered spatial transcriptomics data
  3. Spatial Analysis Functions (Spatial_function.py): Collection of statistical methods for spatial analysis
  4. Spatial Visualization Functions (Plot_Spatial_Image.py): Functions for visualizing spatial relationships

Installation

conda create -n SpatioloJI python=3.12 -y
pip install SpatioloJI

Tutorials

Please check SpatioloJI Documentation for detailed instructions.

Spatial Stats Analysis Categories

SpatioloJI provides functions for spatial ststs in the following categories:

  1. Neighbor Analysis

    • perform_neighbor_analysis: Comprehensive analysis of neighboring cells based on polygon geometries
    • calculate_nearest_neighbor_distances: Calculates distances to nearest neighbors for each cell
    • calculate_cell_density: Measures local cell density within a specified radius
  2. Spatial Pattern Analysis

    • calculate_ripleys_k: Analyzes spatial point patterns using Ripley's K function
    • calculate_cross_k_function: Examines spatial relationships between different cell types
    • calculate_j_function: Uses Baddeley's J-function for spatial pattern analysis
    • calculate_g_function: Analyzes nearest neighbor distance distributions
    • calculate_pair_correlation_function: Measures correlations between cells at different distances
  3. Cell Type Interaction Analysis

    • calculate_cell_type_correlation: Measures how different cell types correlate in space
    • calculate_colocation_quotient: Quantifies spatial relationships between cell types
    • calculate_proximity_analysis: Measures distances between specific cell types
  4. Heterogeneity and Clustering

    • calculate_morisita_index: Measures the spatial distribution pattern (clustered vs. uniform)
    • calculate_quadrat_variance: Analyzes how variance changes with grid size
    • calculate_spatial_entropy: Quantifies randomness in spatial distribution
    • calculate_hotspot_analysis: Identifies statistically significant spatial hot/cold spots
    • calculate_spatial_autocorrelation: Measures Moran's I and related statistics
    • calculate_kernel_density: Creates density maps of cell distributions
    • calculate_spatial_heterogeneity: Quantifies and characterizes spatial variation
  5. Network-Based Analysis

    • calculate_network_statistics: Creates and analyzes cell interaction networks
    • calculate_spatial_context: Analyzes cell neighborhoods and their composition
  6. Gene Expression Spatial Analysis

    • calculate_gene_spatial_autocorrelation: Examines spatial patterns of gene expression
    • calculate_mark_correlation: Analyzes spatial correlation of cell attributes

Contributing

Contributions to SpatioloJI are welcome! Please feel free to submit a pull request or open an issue to discuss your ideas.

License

SpatioloJI is released under the MIT License.

Citation

If you use SpatioloJI in your research, please cite:

Citation information coming soon

Acknowledgments

SpatioloJI builds upon several established algorithms and methods for spatial analysis, and we thank the community for their contributions to this field.

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

spatioloji-0.2.1.tar.gz (74.5 kB view details)

Uploaded Source

Built Distribution

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

spatioloji-0.2.1-py3-none-any.whl (75.4 kB view details)

Uploaded Python 3

File details

Details for the file spatioloji-0.2.1.tar.gz.

File metadata

  • Download URL: spatioloji-0.2.1.tar.gz
  • Upload date:
  • Size: 74.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.9

File hashes

Hashes for spatioloji-0.2.1.tar.gz
Algorithm Hash digest
SHA256 cba3f9a8319b3b47be2273735dab2bf4195d8bc51d0d348be3031fe2e916a958
MD5 a6c894e5f2c678da621db1c51ac6a425
BLAKE2b-256 391f33a904f4ea8de6a5e4240dfd5858416e6f2f2fa4a5b9c5fd7be829b6b492

See more details on using hashes here.

File details

Details for the file spatioloji-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: spatioloji-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 75.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.9

File hashes

Hashes for spatioloji-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a0a08e39d6e4609840ad57e05f4550b80870dbd70dc7b5386780ec2763cb85b8
MD5 de9fa0d01d1152693b57ca8b3d5c5a3f
BLAKE2b-256 42653b6285d9b1d1be8ee6111356c78030bfc065dc540b96d35089cc685aff8c

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