EzDataset-class | R Documentation |
Use this to create an object of the class EzDataset that contains the necessary fields for the input and output datasets.
file
a character representing the file path of the dataset's contents.
meta
a data.frame containing the information about the samples.
colNames
a character vector of the column names in meta
.
tags
a list with possible tags for colNames
.
isModified
whether the dataset has been modified.
columnHasTag(tag)
Checks each column whether its tags
matches tag
.
getColumn(names)
Gets the column(s) selected with names
.
getFullPaths(name)
Gets the files in the nameed column prepended with the dataRoot
.
getLength()
Gets the number of samples.
getNames()
Gets the row names.
setColumn(name, values)
Sets the column selected with name
to values
. If values
is NULL
the column gets removed
subset(samples)
Subsets the meta field keeping samples
and generates a new EzDataset
ezTagListFromNames(names):
Gets the tags from names
that are in the format [tag].
Rehrauer, Hubert
Schmid, Peter
file = system.file("extdata/yeast_10k/dataset.tsv", package="ezRun", mustWork = TRUE)
dataRoot = system.file(package="ezRun", mustWork = TRUE)
ds = EzDataset$new(file=file, dataRoot=dataRoot)
ds$file
ds$meta
ds$getColumn("Read1")
ds$getFullPaths("Read1")
ds2 = ds$copy()
ds2$setColumn("Read1","replacement")
ds$columnHasTag("File")
ds$getNames()
ds$meta$"Genotype [Factor]"[1] = "a"
ds2 = EzDataset$new(meta = ds$meta, dataRoot=dataRoot)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.