Slide 1

Slide 1 text

@lcolladotor lcolladotor.github.io lcolladotor.github.io/bioc_team_ds An Introduction to spatialLIBD: an R/Bioconductor package to visualize spatially-resolved transcriptomics data Leonardo Collado Torres, LIBD Investigator + Asst. Prof. Johns Hopkins Biostatistics Festival of Genomics & Biodata June 13 2024 Slides available at speakerdeck.com/lcolladotor

Slide 2

Slide 2 text

doi.org/10.1016/j.biopsych.2020.06.005 Michael Gandal @mikejg84 Transcriptomic Insight Into the Polygenic Mechanisms Underlying Psychiatric Disorders

Slide 3

Slide 3 text

Background: Human DLPFC 3 slideshare.net Louise A Huuki-Myers @lahuuki

Slide 4

Slide 4 text

Zoom in: spatial omics Kristen R Maynard @kr_maynard Keri Martinowich @martinowk Stephanie C Hicks @stephaniehicks Andrew E Jaffe @andrewejaffe Stephanie C Page @CerceoPage

Slide 5

Slide 5 text

Visium Platform for Spatial Gene Expression Image from 10x Genomics - A slide contains 4 capture areas, each full of thousands of 55um-wide “spots” (often containing 1-10 cells) - Unique barcodes in each spot bind to particular genes; after sequencing, gene expression can be tied back to exact spots, forming a spatial map Kristen R. Maynard 5

Slide 6

Slide 6 text

bioconductor.org/packages/spatialLIBD Pardo et al, 2022 DOI 10.1186/s12864-022-08601-w Maynard, Collado-Torres, 2021 DOI 10.1038/s41593-020-00787-0 Brenda Pardo Abby Spangler @PardoBree @abspangler Louise A. Huuki-Myers @lahuuki

Slide 7

Slide 7 text

2 pairs spatial adjacent replicates x subject = 12 sections 7 Subject 1 Subject 2 Subject 3 Adjacent spatial replicates (0μm) Adjacent spatial replicates (300μm) PCP4 Maynard, Collado-Torres, et al, Nat Neuro, 2021

Slide 8

Slide 8 text

“Pseudo-bulking” collapses data: spot to layer level 8 Maynard, Collado-Torres, et al, Nat Neuro, 2021

Slide 9

Slide 9 text

DOI: 10.1038/s41593-020-00787-0 twitter.com/lcolladotor/status/1233661576433061888 from 2020-02-29 Andrew E Jaffe @andrewejaffe Kristen R Maynard @kr_maynard Keri Martinowich @martinowk

Slide 10

Slide 10 text

DOI: 10.1038/s41593-020-00787-0 twitter.com/lcolladotor/status/1233661576433061888 from 2020-02-29 DOI 10.1093/bioinformatics/btac299 Since Feb 2020 spatialLIBD::fetch_data() provides access to SpatialExperiment R/Bioconductor objects Stephanie C Hicks @stephaniehicks Lukas M Weber @lmweber

Slide 11

Slide 11 text

DOI: 10.1038/s41593-020-00787-0 twitter.com/lcolladotor/status/1233661576433061888 from 2020-02-29 twitter.com/CrowellHL/status/1597579271945715717 DOI 10.1093/bioinformatics/btac299 Since Feb 2020 spatialLIBD::fetch_data() provides access to SpatialExperiment R/Bioconductor objects

Slide 12

Slide 12 text

Pseudobulk to find DE genes DOI: 10.1038/s41593-020-00787-0

Slide 13

Slide 13 text

Single cell analysis workflow bioconductor.org/books/release/OSCA Solid foundational base for getting started with the world of spatial transcriptomics (with Visium)

Slide 14

Slide 14 text

Some challenges ⚠ with Visium 14

Slide 15

Slide 15 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper() ● Spot QC ○ Drop high mitochondria % spots? ○ Drop spots with low UMI counts? ■ Biological vs technical reasons ● Spot clustering (spatially-aware) and/or manual annotation ● Choosing a spot clustering resolution ○ Can be guided by spatially cluster registration

Slide 16

Slide 16 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools)

Slide 17

Slide 17 text

Align your data with spaceranger --count 17 www.10xgenomics.com/support/software/space-ranger/latest

Slide 18

Slide 18 text

Loupe Browser Manually: ● Align fiducial frame ● Select spots “in tissue” lmweber.org/Visium- data-preprocessing/

Slide 19

Slide 19 text

spatialLIBD: visualize SpatialExperiment R objects 19 bioconductor.org/packages/spatialLIBD

Slide 20

Slide 20 text

spatialLIBD::vis_*() functions

Slide 21

Slide 21 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper()

Slide 22

Slide 22 text

spatialLIBD::read10xVisiumWrapper() 22 bioconductor.org/packages/spatialLIBD

Slide 23

Slide 23 text

spatialLIBD::run_app() 23 libd.shinyapps.io/Habenula_Visium_raw/ Default non-spatially aware graph based clustering results + K-means (k = 2 to 10)

Slide 24

Slide 24 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper() ● Spot QC ○ Drop high mitochondria % spots? ○ Drop spots with low UMI counts?

Slide 25

Slide 25 text

sc/snRNA-seq QC metrics such as # detected genes, # UMI, mitochondria expression % are likely biologically related!

Slide 26

Slide 26 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper() ● Spot QC ○ Drop high mitochondria % spots? ○ Drop spots with low UMI counts? ■ Biological vs technical reasons

Slide 27

Slide 27 text

isOutlier(sce.416b$sum, log=TRUE, type="lower") drive.google.com/drive/folders/1cn5d-Ey7-kkMiex8-74qxvxtCQT6o72h Slide by Peter Hickey

Slide 28

Slide 28 text

doi.org/10.1089/genbio.2023.0019 Fig S9 Low library size (UMIs, # detected genes): ● Biological: ○ Not all cells / layers are equally active ● Technical: ○ Edge of tissue: should have been called “out of tissue” ○ Truly low quality

Slide 29

Slide 29 text

Prashanthi Ravichandran @prashanthi-ravichandran (GH) Artifacts in general are normalized away by library size, though there are caveats doi.org/10.1126/science.adh1938

Slide 30

Slide 30 text

Diffusion issues: could be related to permeabilization step doi.org/10.1126/science.adh1938

Slide 31

Slide 31 text

Having more data is useful to provide context! Here 4 new samples have low sequencing saturation (outliers) but are within range of good samples from other studies

Slide 32

Slide 32 text

Having more data is useful to provide context! Those 4 samples have great median UMI counts per spot ^_^

Slide 33

Slide 33 text

Software keeps evolving and as leaders in the field we aim to use the best methods 33 Moses, L., Pachter, L. Museum of spatial transcriptomics. Nat Methods 19, 534–546 (2022). https://doi.org/10.1038/s41592-022-01409-2

Slide 34

Slide 34 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper() ● Spot QC ○ Drop high mitochondria % spots? ○ Drop spots with low UMI counts? ■ Biological vs technical reasons ● Spot clustering (spatially-aware) and/or manual annotation

Slide 35

Slide 35 text

Visualize known marker genes

Slide 36

Slide 36 text

Visualize known marker genes: manually annotate

Slide 37

Slide 37 text

37 bioconductor.org/packages/spatialLIBD Visualizing multiple genes

Slide 38

Slide 38 text

38 bioconductor.org/packages/spatialLIBD Spatially-aware clustering results BayesSpace PRECAST …

Slide 39

Slide 39 text

Some analysis differences ● 10x Genomics CellRanger → SpaceRanger (or other tools) ● DropletUtils::read10xVisium() → spatialLIBD::read10xVisiumWrapper() ● Spot QC ○ Drop high mitochondria % spots? ○ Drop spots with low UMI counts? ■ Biological vs technical reasons ● Spot clustering (spatially-aware) and/or manual annotation ● Choosing a spot clustering resolution ○ Can be guided by spatially cluster registration

Slide 40

Slide 40 text

40 bioconductor.org/packages/spatialLIBD doi.org/10.1126/science.adh1938

Slide 41

Slide 41 text

spatialLIBD::registration_wrapper() + layer_stat_cor() 41 doi.org/10.1126/science.adh1938

Slide 42

Slide 42 text

spatialLIBD apps ● Useful for visualizing & annotating the data ● Immediately make them after running SpaceRanger ● Update them as we generate more results ● Share them with the publication of the results ● spatial.libd.org/spatialLIBD/ ● research.libd.org/spatialDLPFC/#interactive-websites ● research.libd.org/Visium_SPG_AD/#interactive-websites ● …

Slide 43

Slide 43 text

43 research.libd.org/rstatsclub LIBD rstats club videos

Slide 44

Slide 44 text

44 research.libd.org/rstatsclub LIBD rstats club videos

Slide 45

Slide 45 text

lcolladotor.github.io/#projects ● Every assay has caveats ● We re-use tricks: think adding 0, multiplying by 1 ● It nearly always takes a team ● Data sharing accelerates science + democratizes access to it ● Zooming in allows us to reduce the heterogeneity ● We can learn from each other: from uniformly processing our data & re-using it → replicate / validate?

Slide 46

Slide 46 text

@MadhaviTippani Madhavi Tippani @HeenaDivecha Heena R Divecha @lmwebr Lukas M Weber @stephaniehicks Stephanie C Hicks @abspangler Abby Spangler @martinowk Keri Martinowich @CerceoPage Stephanie C Page @kr_maynard Kristen R Maynard @lcolladotor Leonardo Collado-Torres @Nick-Eagles (GH) Nicholas J Eagles Kelsey D Montgomery Sang Ho Kwon Image Analysis Expression Analysis Data Generation Thomas M Hyde @lahuuki Louise A Huuki-Myers @BoyiGuo Boyi Guo @mattntran Matthew N Tran @sowmyapartybun Sowmya Parthiban Slides available at speakerdeck.com /lcolladotor + Many more LIBD, JHU, and external collaborators @mgrantpeters Melissa Grant-Peters @prashanthi-ravichandran (GH) Prashanthi Ravichandran

Slide 47

Slide 47 text

lcolladotor.github.io @lcolladotor