Read BIDCell output

readBIDCell(
  data_dir,
  meta_idx = NULL,
  tiff_path = NULL,
  method_name = NULL,
  spatialCoordsNames = c("cell_centroid_x", "cell_centroid_y")
)

Arguments

data_dir

a character specifying a single output directory as returned by BIDCell, corresponding to one sample.

meta_idx

a numeric vector indicating the indices of the column that corresponding to the meta data in the output files.

tiff_path

a character specifying the path of a tiff file output from BIDCell.

method_name

a character specifying the name of the method.

spatialCoordsNames

a vector of two characters indicate the name of the spatial coordinates for each cell.

Value

A SpatialExperiment object

Examples


data_dir <- system.file("extdata/BIDCell_csv_output", package = "CellSPA")
tiff_path <- system.file("extdata/BIDCell_output_subset.tif", package = "CellSPA")
spe <- readBIDCell(data_dir,
                   tiff_path = tiff_path,
                   method_name = "BIDCell")