Condition {grandR}R Documentation

Get or set the conditions in the column annotation table.

Description

The conditions column from the column annotation table is used by several functions to stratify the columns (samples or cells) during the analysis (e.g. to estimate separate kinetic parameters with FitKinetics or it is used as covariate for LFC or LikelihoodRatioTest). For that reason there are special functions to set and get this column.

Usage

Condition(data, value = NULL)

Condition(data) <- value

Arguments

data

A grandR object

value

Either a vector of column names from the column annotation table, or the condition names themselves

Details

If the conditions column does not exist (or has been set to NULL), all analysis functions will work without stratifying samples or cells. The condition can also be set up directly when loading data, by using Condition as one of the design vector entries (see below).

The condition can be set either by data<-Condition(data,names) or by Condition(data)<-names.

Value

Either the values of the condition column for Condition(data) or the grandR data object having the new condition column

See Also

Coldata

Examples

sars <- ReadGRAND(system.file("extdata", "sars.tsv.gz", package = "grandR"),
                  design=c("Cell",Design$dur.4sU,Design$Replicate))

Condition(sars)
Condition(sars) <- c("Cell","duration.4sU.original")
Condition(sars)

sars <- ReadGRAND(system.file("extdata", "sars.tsv.gz", package = "grandR"),
                  design=c("Condition",Design$dur.4sU,Design$Replicate))
Condition(sars)


[Package grandR version 0.2.5 Index]