name: inverse layout: true class: center, middle, inverse
--- # Clustering 3K PBMCs with Scanpy --- ## Requirements Before diving into this slide deck, we recommend you to have a look at: - [Introduction to Galaxy Analyses](/archive/2020-12-01/topics/introduction) - [Sequence analysis](/archive/2020-12-01/topics/sequence-analysis) - Quality Control: [
slides](/archive/2020-12-01/topics/sequence-analysis/tutorials/quality-control/slides.html) - [
hands-on](/archive/2020-12-01/topics/sequence-analysis/tutorials/quality-control/tutorial.html) - Mapping: [
slides](/archive/2020-12-01/topics/sequence-analysis/tutorials/mapping/slides.html) - [
hands-on](/archive/2020-12-01/topics/sequence-analysis/tutorials/mapping/tutorial.html) .footnote[Tip: press `P` to view the presenter notes] ??? Presenter notes contain extra information which might be useful if you intend to use these slides for teaching. Press `P` again to switch presenter notes off Press `C` to create a new window where the same presentation will be displayed. This window is linked to the main window. Changing slides on one will cause the slide to change on the other. Useful when presenting. --- ### <i class="far fa-question-circle" aria-hidden="true"></i><span class="visually-hidden">question</span> Questions - What are the main steps of scRNA-seq? - What kind of variation can confound an analysis? --- ### <i class="fas fa-bullseye" aria-hidden="true"></i><span class="visually-hidden">objectives</span> Objectives - Learn the main stages of an scRNA-seq analysis - Understand the methods and concepts underlying scRNA-seq --- ### Single Cell RNA Pre-processing ![fig01](../../images/scrna_preproc.svg) ??? 1. Barcode Extraction 1. Mapping 1. Gene Annotation 1. Batch count matrices --- ### Single Cell RNA Downstream Analysis ![fig10](../../images/scrna_downstream.svg) ??? 1. Filtering 1. Normalising * Confounder Removal 1. Dimension Reduction 1. Clustering * Annotation --- ### Barcoding Cells ![fig1](../../images/scrna_pbb_barcodes_add.svg) --- ### Filtering: Cell and Gene ![fig2](../../images/raceid_libsize.svg) --- ### Normalisation: Technical Variation ![fig3](../../images/raceid_technical_variation.svg) --- ### Normalisation: Biological Variation ![fig4](../../images/raceid_cellcycle.svg) --- ### Dimension Reduction: Relatedness of Cells ![fig5](../../images/scrna_knn.svg) ??? Build a KNN graph from distance matrix: * If P and q share distance which is --- ### Dimension Reduction: Projection ![fig6](../../images/raceid_dimred.svg) ??? - Can use tSNE, PCA, UMAP --- ### Community Clustering: Louvain Aim: Maximise internal links and minimise external links ![fig7](../../images/commgraph1.svg) --- ### Community Clustering: Louvain Pick a cell, place in neighbour, and accept if *internal:external* increases ![fig8](../../images/commgraph2.svg) --- ### Cell Type: Identifying Cluster Types .left-column50[.image-100[![fig9](../../images/singlecellplot3.png)]] .left-column50[.image-100[![fig10](../../images/singlecellplot4.png)]] --- ### Clustering: Hard vs Soft .pull-left[ <br /> .image-100[![fig11](../../images/singlecellplot3.png)] *Hard* * Big spaces between clusters * Cell types are well defined and the clustering reflects that ] -- .pull-right[ .image-100[![fig12](../../images/10xdata.png)] *Soft* * Clusters bleed into one another * Cell types seem to intermingle with one another. ] ??? Why? Why would there be clusters so close to one another? --- ### Continuous Phenotypes: .image-100[![fig13](../../images/raceid_contpheno.svg)] ??? * Cells aren't discrete, they transition * Continuously changing over time from a less mature type to more mature type --- ### Interactive Environments: live.usegalaxy.eu <br/> <video style="width:100%;height:auto;" controls> <source src="https://zenodo.org/record/3687100/files/live_cellxgene.mp4" /> </video> ??? What is Differential Expression in scRNA-seq? --- ### CellxGene Local Test * We can probe clusters to see how they are so differentially expressed pip3 install cellxgene cellxgene launch https://cellxgene-example-data.czi.technology/pbmc3k.h5ad * Launch locally: http://127.0.0.1:5005 --- ### <i class="fas fa-key" aria-hidden="true"></i><span class="visually-hidden">keypoints</span> Key points - Understanding the purpose of barcoding - Knowing the difference between hard and soft clustering - A KNN graph can be generated from a count matrix. - Community clustering can be generated from a KNN graph. - Interpreting scRNA-seq plots --- ## Thank you! This material is the result of a collaborative work. Thanks to the [Galaxy Training Network](https://wiki.galaxyproject.org/Teach/GTN) and all the contributors!
This material is licensed under the
Creative Commons Attribution 4.0 International License