From 4a188bf3369f35b55b10862e47acd0bbfd0def3e Mon Sep 17 00:00:00 2001 From: lcolladotor Date: Fri, 24 May 2024 05:57:03 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20LieberIn?= =?UTF-8?q?stitute/spatialLIBD@cb1591ecd26f529a31b603c029baa82db8171989=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- articles/TenX_data_download.html | 544 ++++++++------- articles/guide_to_spatial_registration.html | 410 +++++------ articles/multi_gene_plots.html | 379 +++++----- articles/spatialLIBD.html | 691 ++++++++++--------- pkgdown.yml | 4 +- reference/add_images.html | 26 +- reference/add_key.html | 2 +- reference/annotate_registered_clusters.html | 2 +- reference/check_modeling_results.html | 2 +- reference/check_sce.html | 2 +- reference/check_sce_layer.html | 2 +- reference/check_spe.html | 2 +- reference/cluster_export.html | 2 +- reference/cluster_import.html | 6 +- reference/fetch_data.html | 2 +- reference/frame_limits.html | 2 +- reference/gene_set_enrichment.html | 2 +- reference/gene_set_enrichment_plot.html | 2 +- reference/geom_spatial.html | 2 +- reference/get_colors.html | 2 +- reference/img_edit.html | 2 +- reference/img_update.html | 2 +- reference/img_update_all.html | 2 +- reference/layer_boxplot.html | 4 +- reference/layer_stat_cor.html | 2 +- reference/layer_stat_cor_plot.html | 2 +- reference/registration_block_cor.html | 12 +- reference/registration_model.html | 8 +- reference/registration_pseudobulk.html | 6 +- reference/registration_stats_anova.html | 18 +- reference/registration_stats_enrichment.html | 20 +- reference/registration_stats_pairwise.html | 20 +- reference/registration_wrapper.html | 24 +- reference/sce_to_spe.html | 2 +- reference/sig_genes_extract.html | 4 +- reference/sig_genes_extract_all.html | 4 +- reference/vis_clus.html | 2 +- reference/vis_clus_p.html | 2 +- reference/vis_gene.html | 2 +- reference/vis_gene_p.html | 2 +- reference/vis_grid_clus.html | 2 +- reference/vis_grid_gene.html | 2 +- 42 files changed, 1126 insertions(+), 1104 deletions(-) diff --git a/articles/TenX_data_download.html b/articles/TenX_data_download.html index 60f7ef38..bb0bfd4d 100644 --- a/articles/TenX_data_download.html +++ b/articles/TenX_data_download.html @@ -135,11 +135,11 @@

Basics

Install spatialLIBD

R is an open-source statistical environment which can be -easily modified to enhance its functionality via packages. spatialLIBD +easily modified to enhance its functionality via packages. spatialLIBD (Pardo, Spangler, Weber, Hicks, Jaffe, Martinowich, Maynard, and Collado-Torres, 2022) is an R package available via the Bioconductor repository for packages. R can be installed on any operating system from CRAN after which you can install -spatialLIBD +spatialLIBD by using the following commands in your R session:

 if (!requireNamespace("BiocManager", quietly = TRUE)) {
@@ -173,7 +173,7 @@ 

Required knowledge

Citing spatialLIBD

-

We hope that spatialLIBD +

We hope that spatialLIBD will be useful for your research. Please use the following information to cite the package and the overall approach. Thank you!

@@ -224,10 +224,10 @@ 

Citing spatialLIBD

Download data from 10x Genomics

-

In this vignette we’ll show you how you can use spatialLIBD +

In this vignette we’ll show you how you can use spatialLIBD (Pardo, Spangler, Weber et al., 2022) for exploring spatially resolved transcriptomics data from the Visium -platform by 10x Genomics. That is, you will learn how to use spatialLIBD +platform by 10x Genomics. That is, you will learn how to use spatialLIBD for data beyond the one it was initially developed for (Maynard, Collado-Torres, Weber, Uytingco, Barry, Williams, II, Tran, Besich, Tippani, Chew, Yin, Kleinman, Hyde, Rao, Hicks, Martinowich, and Jaffe, @@ -242,20 +242,20 @@

Load packagesBiocFileCache: +BiocFileCache: for downloading and saving a local cache of the data
  • -SpatialExperiment: +SpatialExperiment: for reading the spaceranger files provided by 10x Genomics
  • -rtracklayer: +rtracklayer: for importing a gene annotation GTF file
  • lobstr: for checking how much memory our object is using
  • -spatialLIBD: +spatialLIBD: for launching an interactive website to explore the data
  • @@ -271,11 +271,11 @@ 

    Download spaceranger output files

    Next we download data from 10x Genomics available from the human lymph node example, available at https://support.10xgenomics.com/spatial-gene-expression/datasets/1.1.0/V1_Human_Lymph_Node. -We don’t need to download all the files listed there since SpatialExperiment +We don’t need to download all the files listed there since SpatialExperiment doesn’t need all of them for importing the data into R. These files are part of the output that gets generated by spaceranger which is the processing pipeline provided by 10x Genomics for Visium data.

    -

    We’ll use BiocFileCache +

    We’ll use BiocFileCache to keep the data in a local cache in case we want to run this example again and don’t want to re-download the data from the web.

    +

    Now that we have the files that we need, we can import the data into -R using read10xVisium() from SpatialExperiment. +R using read10xVisium() from SpatialExperiment. We’ll import the low resolution histology images produced by spaceranger using the images = "lowres" and load = TRUE arguments. We’ll also load the filtered gene @@ -336,7 +337,7 @@

    Download spaceranger output filestype = "sparse" argument to load the data into an R object that is memory-efficient for sparse data.

    -
    +
     ## Import the data as a SpatialExperiment object
     spe <- SpatialExperiment::read10xVisium(
         samples = tempdir(),
    @@ -349,10 +350,12 @@ 

    Download spaceranger output filesclass(spe) #> [1] "SpatialExperiment" #> attr(,"package") -#> [1] "SpatialExperiment" -lobstr::obj_size(spe) / 1024^2 ## Convert to MB -#> 281.90 B -spe +#> [1] "SpatialExperiment"

    +
    +lobstr::obj_size(spe) / 1024^2 ## Convert to MB
    +#> 281.90 B
    + +
    +
     ## The counts are saved in a sparse matrix R object
     class(counts(spe))
     #> [1] "dgCMatrix"
    @@ -400,7 +404,7 @@ 

    Modify spe for spatialLIBDsum_gene: this continuous variable contains the number of genes that have at least 1 count. -
    +
     ## Add some information used by spatialLIBD
     spe <- add_key(spe)
     spe$sum_umi <- colSums(counts(spe))
    @@ -419,7 +423,7 @@ 

    Add gene annotation information -
    +
     ## Initially we don't have much information about the genes
     rowRanges(spe)
     #> GRangesList object of length 36601:
    @@ -462,14 +466,14 @@ 

    From 10xSpatialExperiment::read10xVisium() does not include.

    For example, in our computing cluster this GTF file is located at the following path and is 1.4 GB in size:

    -
    $ cd /dcs04/lieber/lcolladotor/annotationFiles_LIBD001/10x/refdata-gex-GRCh38-2020-A
    -$ du -sh --apparent-size genes/genes.gtf
    -1.4G    genes/genes.gtf
    +
    $ cd /dcs04/lieber/lcolladotor/annotationFiles_LIBD001/10x/refdata-gex-GRCh38-2020-A
    +$ du -sh --apparent-size genes/genes.gtf
    +1.4G    genes/genes.gtf

    If you have the GTF file from 10x Genomics, we show next how you can read the information into R, match it appropriately with the information in the spe object and add it back into the spe object.

    -
    +
     ## You could:
     ## * download the 11 GB file from
     ## https://cf.10xgenomics.com/supp/cell-exp/refdata-gex-GRCh38-2020-A.tar.gz
    @@ -521,7 +525,7 @@ 

    From Gencode
    +
    +
    +
    +
     ## Drop the few genes for which we don't have information
     spe <- spe[!is.na(match_genes), ]
     match_genes <- match_genes[!is.na(match_genes)]
    @@ -615,7 +621,7 @@