A small example package
Project description
Enhanced Scanpy Clustering
A collection of tools and workflows to improve clustering analysis in single-cell RNA-seq data using Scanpy.
Features
- Advanced clustering algorithms and parameter tuning
- Visualization enhancements for cluster interpretation
- Utilities for preprocessing and quality control
- Integration with AnnData objects
Installation
pip install enhanced-scanpy-clustering
Or, for development:
git clone https://github.com/Terrell-byte/enhanced-scanpy-clustering.git
cd enhanced-scanpy-clustering
pip install -e .
Usage
Describe the main ways to use the package here.
Command-line usage
# Run the main workflow
python -m enhanced_scanpy_clustering.main --input <input_file> --output <output_dir>
# Additional options
python -m enhanced_scanpy_clustering.main \
--input <input_file> \
--output <output_dir> \
--algorithm dbscan_base \
--neighbors 15 \
--resolution 0.5 \
--random-state 42
Python usage
import scanpy as sc
import enhanced_scanpy_clustering.clustering as cl
# Option 1: Use the cluster function
cl.cluster(adata, algorithm="...", key_added='...')
# Option 2: Use direct Scanpy integration
cl.enable_scanpy_integration()
Note:
- The package requires AnnData objects as input
- Recommended to normalize and preprocess your data before clustering
- Set random seed for reproducible results
Examples
import scanpy as sc
import enhanced_scanpy_clustering.clustering as cl
# Load adata with you data set
adata = sc.read_h5ad('YourFile.h5ad')
# 1: Using only neccesary paremeters with algo "DBScan_Base"
cl.cluster(adata, algorithm='DBScan_Base', key_added='dbscan_labels')
# 2: Using Scanpy integration
cl.enable_scanpy_integration()
sc.tl.DBScan_Base(adata, key_added='dbscan_labels')
# 3: Additional parameters for fine-tuning
cl.cluster(
adata,
algorithm='DBScan_Base',
key_added='dbscan_labels',
n_neighbors=15,
resolution=0.5,
random_state=42
)
Contributing
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file rna_clustering_algorithms-0.1.4.tar.gz.
File metadata
- Download URL: rna_clustering_algorithms-0.1.4.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
036ebec8d57bf0031955e8c0dedd453dbe74d300928d9e51ee84c6393dbf7296
|
|
| MD5 |
233af6d090689d1e2b07e5e6dcf1c29d
|
|
| BLAKE2b-256 |
854915b81be6dcea87f24b6258de6c53d7e5fc9adb35dc979b62ce5d805a413f
|
File details
Details for the file rna_clustering_algorithms-0.1.4-py3-none-any.whl.
File metadata
- Download URL: rna_clustering_algorithms-0.1.4-py3-none-any.whl
- Upload date:
- Size: 10.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a8a0f37b3bf6c81cca570c24507c1f3977e092933f5f92a5d7a1e3904dfe6fe7
|
|
| MD5 |
2d7978155b195936413adda71d2087bd
|
|
| BLAKE2b-256 |
ba36d2451cd5a64c0c02c50b3ddf4d65df838de1af877aaefea1aecd15dec13f
|