Method to extract image info
GetImageInfo.Rd
Method to extract image info
Usage
GetImageInfo(object)
# S4 method for class 'Staffli'
GetImageInfo(object)
# S4 method for class 'Seurat'
GetImageInfo(object)
Examples
# Load example data
se_mbrain <- readRDS(system.file("extdata/mousebrain", "se_mbrain", package = "semla")) |>
LoadImages()
#>
#> ── Loading H&E images ──
#>
#> ℹ Loading image from /private/var/folders/8r/bfm2m_q17znfk0m_8dt330tm0000gp/T/RtmpLHpYU7/temp_libpath305b1609463d/semla/extdata/mousebrain/spatial/tissue_lowres_image.jpg
#> ℹ Scaled image from 600x565 to 400x377 pixels
#> ℹ Saving loaded H&E images as 'rasters' in Seurat object
# Fetch Staffli object
staffli_object <- GetStaffli(se_mbrain)
# Fetch images from a Staffli object
image_info <- GetImageInfo(staffli_object)
image_info
#> # A tibble: 1 × 10
#> format width height full_width full_height colorspace filesize density
#> <chr> <int> <int> <dbl> <dbl> <chr> <int> <chr>
#> 1 JPEG 1882 2000 18107. 19242. sRGB 1030876 72x72
#> # ℹ 2 more variables: sampleID <chr>, type <chr>
# Fetch images from a Seurat object
image_info <- GetImageInfo(se_mbrain)
image_info
#> # A tibble: 1 × 10
#> format width height full_width full_height colorspace filesize density
#> <chr> <int> <int> <dbl> <dbl> <chr> <int> <chr>
#> 1 JPEG 1882 2000 18107. 19242. sRGB 1030876 72x72
#> # ℹ 2 more variables: sampleID <chr>, type <chr>