R/test-data.R

Defines functions get_test_counts_matrix

Documented in get_test_counts_matrix

#' Get an example counts matrix.
#'
#' Get a small matrix of raw counts from the PBMC dataset.
#'
#' @return A matrix of raw counts.
#'
#' @examples
#' pbmc_mat <- get_test_counts_matrix()
#'
#' @importFrom utils read.table
#' @export
get_test_counts_matrix <- function() {
  pbmc_raw <- read.table(
    file = system.file("extdata", "pbmc.txt", package = "scooter"),
    as.is = TRUE,
    check.names = FALSE
  )
  as.matrix(pbmc_raw)
}
igordot/scooter documentation built on Nov. 20, 2023, 5:55 a.m.