Contents

1 Installation

This package can be installed from Bioconductor with the following command:

if (!requireNamespace(BiocManager, quietly = TRUE)) install.packages("BiocManager")
BiocManager::install("SFEData")

2 Usage

library(SFEData)

Example spatial transcriptomics datasets with Simple Features annotations as SpatialFeatureExperiment objects. These are the datasets available from this package and functions to download the datasets:

Visium:

Slide-seq2:

Xenium:

CosMX:

MERFISH:

seqFISH:

Xenium: * Xenium output subset of mouse brain data (XeniumOutput())

This package is used extensively in examples and vignettes of the SpatialFeatureExperiment and Voyager packages. The same function is used for different samples from the same study, and the dataset argument determines which sample is downloaded:

sfe <- McKellarMuscleData(dataset = "small")
#> see ?SFEData and browseVignettes('SFEData') for documentation
#> loading from cache
#> require("SpatialFeatureExperiment")

The outputs (in *Output()) are not SFE objects, but a small subset in the format of the standard output of the technology, used to unit test read functions. Where the files are saved is controlled by the file_path argument.

(fp <- CosMXOutput(file_path = "foo"))
#> see ?SFEData and browseVignettes('SFEData') for documentation
#> loading from cache
#> The downloaded files are in /tmp/Rtmp8Msdr4/Rbuild2fee3015dafca1/SFEData/vignettes/foo/cosmx
#> [1] "/tmp/Rtmp8Msdr4/Rbuild2fee3015dafca1/SFEData/vignettes/foo/cosmx"
unlink("foo", recursive = TRUE)
sessionInfo()
#> R version 4.4.0 beta (2024-04-15 r86425)
#> Platform: x86_64-pc-linux-gnu
#> Running under: Ubuntu 22.04.4 LTS
#> 
#> Matrix products: default
#> BLAS:   /home/biocbuild/bbs-3.19-bioc/R/lib/libRblas.so 
#> LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.10.0
#> 
#> locale:
#>  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
#>  [3] LC_TIME=en_GB              LC_COLLATE=C              
#>  [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
#>  [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
#>  [9] LC_ADDRESS=C               LC_TELEPHONE=C            
#> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       
#> 
#> time zone: America/New_York
#> tzcode source: system (glibc)
#> 
#> attached base packages:
#> [1] stats     graphics  grDevices utils     datasets  methods   base     
#> 
#> other attached packages:
#> [1] SpatialFeatureExperiment_1.6.0 SFEData_1.6.0                 
#> [3] BiocStyle_2.32.0              
#> 
#> loaded via a namespace (and not attached):
#>   [1] jsonlite_1.8.8              wk_0.9.1                   
#>   [3] magrittr_2.0.3              magick_2.8.3               
#>   [5] rmarkdown_2.26              zlibbioc_1.50.0            
#>   [7] vctrs_0.6.5                 spdep_1.3-3                
#>   [9] memoise_2.0.1               DelayedMatrixStats_1.26.0  
#>  [11] RCurl_1.98-1.14             terra_1.7-71               
#>  [13] htmltools_0.5.8.1           S4Arrays_1.4.0             
#>  [15] AnnotationHub_3.12.0        curl_5.2.1                 
#>  [17] BiocNeighbors_1.22.0        Rhdf5lib_1.26.0            
#>  [19] s2_1.1.6                    SparseArray_1.4.0          
#>  [21] rhdf5_2.48.0                sass_0.4.9                 
#>  [23] spData_2.3.0                KernSmooth_2.23-22         
#>  [25] bslib_0.7.0                 htmlwidgets_1.6.4          
#>  [27] cachem_1.0.8                mime_0.12                  
#>  [29] lifecycle_1.0.4             pkgconfig_2.0.3            
#>  [31] Matrix_1.7-0                R6_2.5.1                   
#>  [33] fastmap_1.1.1               GenomeInfoDbData_1.2.12    
#>  [35] MatrixGenerics_1.16.0       digest_0.6.35              
#>  [37] AnnotationDbi_1.66.0        S4Vectors_0.42.0           
#>  [39] dqrng_0.3.2                 ExperimentHub_2.12.0       
#>  [41] GenomicRanges_1.56.0        RSQLite_2.3.6              
#>  [43] beachmat_2.20.0             filelock_1.0.3             
#>  [45] fansi_1.0.6                 httr_1.4.7                 
#>  [47] abind_1.4-5                 compiler_4.4.0             
#>  [49] proxy_0.4-27                bit64_4.0.5                
#>  [51] withr_3.0.0                 tiff_0.1-12                
#>  [53] BiocParallel_1.38.0         DBI_1.2.2                  
#>  [55] HDF5Array_1.32.0            R.utils_2.12.3             
#>  [57] rappdirs_0.3.3              DelayedArray_0.30.0        
#>  [59] rjson_0.2.21                classInt_0.4-10            
#>  [61] tools_4.4.0                 units_0.8-5                
#>  [63] R.oo_1.26.0                 glue_1.7.0                 
#>  [65] EBImage_4.46.0              rhdf5filters_1.16.0        
#>  [67] grid_4.4.0                  sf_1.0-16                  
#>  [69] generics_0.1.3              R.methodsS3_1.8.2          
#>  [71] class_7.3-22                data.table_1.15.4          
#>  [73] sp_2.1-4                    utf8_1.2.4                 
#>  [75] XVector_0.44.0              BiocGenerics_0.50.0        
#>  [77] BiocVersion_3.19.1          pillar_1.9.0               
#>  [79] limma_3.60.0                dplyr_1.1.4                
#>  [81] BiocFileCache_2.12.0        lattice_0.22-6             
#>  [83] bit_4.0.5                   deldir_2.0-4               
#>  [85] tidyselect_1.2.1            SingleCellExperiment_1.26.0
#>  [87] locfit_1.5-9.9              Biostrings_2.72.0          
#>  [89] scuttle_1.14.0              sfheaders_0.4.4            
#>  [91] knitr_1.46                  bookdown_0.39              
#>  [93] IRanges_2.38.0              edgeR_4.2.0                
#>  [95] SummarizedExperiment_1.34.0 stats4_4.4.0               
#>  [97] xfun_0.43                   Biobase_2.64.0             
#>  [99] statmod_1.5.0               DropletUtils_1.24.0        
#> [101] matrixStats_1.3.0           UCSC.utils_1.0.0           
#> [103] fftwtools_0.9-11            yaml_2.3.8                 
#> [105] boot_1.3-30                 evaluate_0.23              
#> [107] codetools_0.2-20            tibble_3.2.1               
#> [109] BiocManager_1.30.22         cli_3.6.2                  
#> [111] jquerylib_0.1.4             Rcpp_1.0.12                
#> [113] GenomeInfoDb_1.40.0         dbplyr_2.5.0               
#> [115] png_0.1-8                   parallel_4.4.0             
#> [117] blob_1.2.4                  jpeg_0.1-10                
#> [119] sparseMatrixStats_1.16.0    bitops_1.0-7               
#> [121] SpatialExperiment_1.14.0    e1071_1.7-14               
#> [123] purrr_1.0.2                 crayon_1.5.2               
#> [125] rlang_1.1.3                 KEGGREST_1.44.0