=========
Tutorials
=========
.. raw:: html
Getting Started
-------------
Before diving into the tutorials, make sure you have:
* :doc:`Installed CellDISECT `
* Familiarized yourself with the :doc:`basic concepts `
* Prepared your single-cell data in the appropriate format
Tutorial Categories
-----------------
Beginner Tutorials
~~~~~~~~~~~~~~~~
.. grid:: 2
.. grid-item-card:: ๐ฌ Basic CellDISECT Training
:link: CellDISECT_Counterfactual.ipynb
:class-card: tutorial-card
Learn how to train CellDISECT and make counterfactual predictions using the Kang dataset.
Perfect for first-time users!
+++
:doc:`Open Notebook `
Perturbation Prediction
~~~~~~~~~~~~~~~~~~~~~~~
.. grid:: 2
.. grid-item-card:: ๐งช Perturbation Prediction
:link: CellDISECT_Perturbation.ipynb
:class-card: tutorial-card
Predict gene expression under seen, unseen, and combinatorial perturbations
using predefined gene embeddings (GenePT, ESM, scGPT).
+++
:doc:`Open Notebook `
Advanced Applications
~~~~~~~~~~~~~~~~~~
.. grid:: 2
.. grid-item-card:: ๐งฌ Latent Space Exploration
:link: Erythroid_subset_inference.ipynb
:class-card: tutorial-card
Explore how to combine CellDISECT latent spaces for erythroid subset inference,
demonstrating advanced usage with Z_0 + Z_Organ integration.
+++
:doc:`Open Notebook `
.. grid-item-card:: ๐ Double Counterfactual Analysis
:link: Eraslan_CF_Tutorial.ipynb
:class-card: tutorial-card
Advanced tutorial recreating Scenario 2 counterfactual predictions on the Eraslan dataset,
as featured in our paper.
+++
:doc:`Open Notebook `
.. note::
Each tutorial includes downloadable Jupyter notebooks that you can run locally.
The notebooks are extensively documented with step-by-step explanations and best practices.
Detailed Tutorial Contents
------------------------
.. toctree::
:maxdepth: 2
:caption: Available Tutorials
:numbered:
CellDISECT_Counterfactual.ipynb
CellDISECT_Perturbation.ipynb
Erythroid_subset_inference.ipynb
Eraslan_CF_Tutorial.ipynb
Tutorial Details
--------------
Basic Training Tutorial
~~~~~~~~~~~~~~~~~~~~~
In this introductory tutorial, you'll learn:
* How to prepare your data for CellDISECT
* Basic model training and configuration
* Making simple counterfactual predictions
* Visualizing and interpreting results
:download:`Download Notebook `
Perturbation Prediction Tutorial
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This tutorial covers:
* Preparing predefined gene embeddings (GenePT, ESM) in ``adata.uns``
* Setting up ``setup_anndata`` with ``perturbation_key`` and ``perturbation_embedding_key``
* Training CellDISECT with perturbation-aware embeddings
* Predicting seen, unseen, and combinatorial perturbations
* Evaluating predictions with ``perturbation_metrics``
:download:`Download Notebook `
Latent Space Analysis
~~~~~~~~~~~~~~~~~~~
This advanced tutorial covers:
* Understanding CellDISECT's latent space structure
* Combining multiple latent spaces (Z_0 + Z_Organ)
* Advanced visualization techniques
* Interpreting latent space representations
:download:`Download Notebook `
Double Counterfactual Tutorial
~~~~~~~~~~~~~~~~~~~~~~~~~~~
This expert-level tutorial demonstrates:
* Complex counterfactual predictions
* Recreating paper results on the Eraslan dataset
* Advanced model configurations
* Result analysis and validation
:download:`Download Notebook `
.. raw:: html