easydecon


Nameeasydecon JSON
Version 0.1.2 PyPI version JSON
download
home_pagehttps://github.com/sinanugur/easydecon
Summaryeasydecon
upload_time2025-10-20 12:26:32
maintainerNone
docs_urlNone
authorSinan U. Umu
requires_pythonNone
licenseNone
keywords scrna single-cell high definition spatial transcriptomics deconvolution
VCS
bugtrack_url
requirements scipy regex matplotlib pandas anndata numpy stardist bin2cell spatialdata spatialdata-io spatialdata-plot xarray-spatial xarray dask ipykernel squidpy joblib xlrd tensorflow-macos tensorflow-metal tensorflow
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <img src="easydecon-logo.png" alt="Logo" width=130 style="vertical-align: middle; margin-right: 10px;"/>  

[![PyPI version](https://badge.fury.io/py/easydecon.svg)](https://badge.fury.io/py/easydecon)  
A package to analyze celltypes on high definition spatial profiling assays

Installation
------------
It is recommended to install the package in a virtual environment or a Conda environment. To create a Conda environment, run the following command:

```bash
conda create -n easydecon python=3.10.14
conda activate easydecon
```

You can install from PyPi:

```bash
pip install easydecon
```

To install directly from GitHub using pip into the active environment, run the following command:

```bash
pip install git+https://github.com/sinanugur/easydecon.git
```

Overview
--------
<img src="easydecon-overview.png" alt="Worfklow Overview"/>

Absolute Minimal Example
---------------
```python
from easydecon.easydecon import *
from easydecon.config import *
from easydecon.extra import *

#read your DESeq table into a markers_df
#sdata is your VisiumHD file in SpatialData format or segmented AnnData object, assumed you QC and etc.
markers_df=read_markers_dataframe(sdata,filename="scanpy_deseq_table.csv")

#run easydecon
ph1, ph2, assigned_labels, posterior_df, proportions_df= easydecon_workflow(sdata,markers_df=markers_df)

#or setting prior genes
ph1, ph2, assigned_labels, posterior_df, proportions_df= easydecon_workflow(sdata,markers_df=markers_df,marker_genes=["gene1","gene2","gene3"])

`assigned_labels` will be added to sdata.obs and contain the celltype assignments
`proportions_df` will contain the estimated proportions for each celltype

```

Usage and Documentation
-----------------------
You may find our example notebooks in the `notebooks` folder.

- Demo notebook for a single-cell Anndata object (demo)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo.ipynb]
- Demo notebook for macrophage markers (demo_macrophage)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo_macrophage.ipynb]
- Minimal example notebook (minimal)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo_minimal_example.ipynb]

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/sinanugur/easydecon",
    "name": "easydecon",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "scRNA single-cell high definition spatial transcriptomics deconvolution",
    "author": "Sinan U. Umu",
    "author_email": "sinanugur@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/e9/98/3c070b5de493b50d55075239d34a6f6068f21a5c7a326909bbcf79a2073d/easydecon-0.1.2.tar.gz",
    "platform": null,
    "description": "<img src=\"easydecon-logo.png\" alt=\"Logo\" width=130 style=\"vertical-align: middle; margin-right: 10px;\"/>  \n\n[![PyPI version](https://badge.fury.io/py/easydecon.svg)](https://badge.fury.io/py/easydecon)  \nA package to analyze celltypes on high definition spatial profiling assays\n\nInstallation\n------------\nIt is recommended to install the package in a virtual environment or a Conda environment. To create a Conda environment, run the following command:\n\n```bash\nconda create -n easydecon python=3.10.14\nconda activate easydecon\n```\n\nYou can install from PyPi:\n\n```bash\npip install easydecon\n```\n\nTo install directly from GitHub using pip into the active environment, run the following command:\n\n```bash\npip install git+https://github.com/sinanugur/easydecon.git\n```\n\nOverview\n--------\n<img src=\"easydecon-overview.png\" alt=\"Worfklow Overview\"/>\n\nAbsolute Minimal Example\n---------------\n```python\nfrom easydecon.easydecon import *\nfrom easydecon.config import *\nfrom easydecon.extra import *\n\n#read your DESeq table into a markers_df\n#sdata is your VisiumHD file in SpatialData format or segmented AnnData object, assumed you QC and etc.\nmarkers_df=read_markers_dataframe(sdata,filename=\"scanpy_deseq_table.csv\")\n\n#run easydecon\nph1, ph2, assigned_labels, posterior_df, proportions_df= easydecon_workflow(sdata,markers_df=markers_df)\n\n#or setting prior genes\nph1, ph2, assigned_labels, posterior_df, proportions_df= easydecon_workflow(sdata,markers_df=markers_df,marker_genes=[\"gene1\",\"gene2\",\"gene3\"])\n\n`assigned_labels` will be added to sdata.obs and contain the celltype assignments\n`proportions_df` will contain the estimated proportions for each celltype\n\n```\n\nUsage and Documentation\n-----------------------\nYou may find our example notebooks in the `notebooks` folder.\n\n- Demo notebook for a single-cell Anndata object (demo)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo.ipynb]\n- Demo notebook for macrophage markers (demo_macrophage)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo_macrophage.ipynb]\n- Minimal example notebook (minimal)[https://github.com/sinanugur/easydecon/blob/main/notebooks/demo_minimal_example.ipynb]\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "easydecon",
    "version": "0.1.2",
    "project_urls": {
        "Homepage": "https://github.com/sinanugur/easydecon"
    },
    "split_keywords": [
        "scrna",
        "single-cell",
        "high",
        "definition",
        "spatial",
        "transcriptomics",
        "deconvolution"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "e9983c070b5de493b50d55075239d34a6f6068f21a5c7a326909bbcf79a2073d",
                "md5": "1479dc08e81a83f8126ac27587416be5",
                "sha256": "e3bac48d5c7f228a75c07a183c28c024976207cacfc140d093d8c54480185a06"
            },
            "downloads": -1,
            "filename": "easydecon-0.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "1479dc08e81a83f8126ac27587416be5",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 1399262,
            "upload_time": "2025-10-20T12:26:32",
            "upload_time_iso_8601": "2025-10-20T12:26:32.129227Z",
            "url": "https://files.pythonhosted.org/packages/e9/98/3c070b5de493b50d55075239d34a6f6068f21a5c7a326909bbcf79a2073d/easydecon-0.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-10-20 12:26:32",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "sinanugur",
    "github_project": "easydecon",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "scipy",
            "specs": []
        },
        {
            "name": "regex",
            "specs": []
        },
        {
            "name": "matplotlib",
            "specs": []
        },
        {
            "name": "pandas",
            "specs": [
                [
                    "==",
                    "2.2.2"
                ]
            ]
        },
        {
            "name": "anndata",
            "specs": [
                [
                    "==",
                    "0.10.9"
                ]
            ]
        },
        {
            "name": "numpy",
            "specs": []
        },
        {
            "name": "stardist",
            "specs": [
                [
                    "==",
                    "0.9.1"
                ]
            ]
        },
        {
            "name": "bin2cell",
            "specs": [
                [
                    "==",
                    "0.3.0"
                ]
            ]
        },
        {
            "name": "spatialdata",
            "specs": [
                [
                    "==",
                    "0.2.2"
                ]
            ]
        },
        {
            "name": "spatialdata-io",
            "specs": [
                [
                    "==",
                    "0.1.4"
                ]
            ]
        },
        {
            "name": "spatialdata-plot",
            "specs": [
                [
                    "==",
                    "0.2.4"
                ]
            ]
        },
        {
            "name": "xarray-spatial",
            "specs": [
                [
                    "==",
                    "0.4.0"
                ]
            ]
        },
        {
            "name": "xarray",
            "specs": [
                [
                    "==",
                    "2024.7.0"
                ]
            ]
        },
        {
            "name": "dask",
            "specs": [
                [
                    "==",
                    "2024.11.2"
                ]
            ]
        },
        {
            "name": "ipykernel",
            "specs": []
        },
        {
            "name": "squidpy",
            "specs": []
        },
        {
            "name": "joblib",
            "specs": []
        },
        {
            "name": "xlrd",
            "specs": [
                [
                    "==",
                    "2.0.1"
                ]
            ]
        },
        {
            "name": "tensorflow-macos",
            "specs": [
                [
                    "==",
                    "2.9.0"
                ]
            ]
        },
        {
            "name": "tensorflow-metal",
            "specs": [
                [
                    "==",
                    "0.5.0"
                ]
            ]
        },
        {
            "name": "tensorflow",
            "specs": [
                [
                    "==",
                    "2.9.0"
                ]
            ]
        }
    ],
    "lcname": "easydecon"
}
        
Elapsed time: 2.19462s