ezCombineReadDatasets: Combine the reads from multiple datasets into a single...

View source: R/datasets.R

ezCombineReadDatasetsR Documentation

Combine the reads from multiple datasets into a single dataset

Description

Takes the union of the samples in multiple input datasets and generates a new dataset.

Usage

  ezCombineReadDatasets(..., dataRoot = "/srv/gstore/projects", newDsDir = NULL)

Arguments

...

tibble objects from the dataset.tsv files.

dataRoot

a character specifying the file root of the datasets.

newDsDir

a character specifying the directory to save the new dataset in.

ds1

a data.frame from the meta field of an EzDataset.

ds2

a data.frame from the meta field of an EzDataset.

Details

If a sample is present in more than one datasets, the read files are concatenated and a new file is written.

If a sample is present in only one dataset it is simply copied.

The ‘Read Count’ column must be present and is updated if two files are combined.

Value

A tibble object of new dataset.

Author(s)

Ge Tan

Examples

  library(readr)
  ds1 <- read_tsv(system.file("extdata/yeast_10k/dataset.tsv",
                              package = "ezRun", mustWork = TRUE))
  ds3 <- ds2 <- ds1
  dataRoot <- path.package("ezRun")
  newDsDir <- "scratch"
  ds <- ezCombineReadDatasets(ds1, ds2, ds3, dataRoot=dataRoot,
                              newDsDir=newDsDir)

uzh/ezRun documentation built on Dec. 26, 2024, 9:53 a.m.