byAttribute: Subset data by an attribute

Description Usage Arguments Value See Also Examples

Description

A more generic function to subset your data by whichever column you want. Even works on vectors, so you can subset by multiple values of an attribute at a time. To remove data by an attribute, see dropAttribute.

Usage

1
byAttribute(obj, string, col)

Arguments

obj

A valid DAM object (created by newExperiment).

string

Attribute values to include. Can be a vector.

col

Which column of attribute values should be used.

Value

Returns a DAM S4 object.

See Also

dropAttribute

Examples

1
2
3
4
5
6
7
listAttribVals(DAM_DD, "genotype")
returnedDAM <- byAttribute(DAM_DD, "experimental")
listAttribVals(returnedDAM, "genotype")

listAttribVals(DAM_DD, "genotype")
returnedDAM <- byAttribute(DAM_DD, c("control A", "control B"))
listAttribVals(returnedDAM, "genotype")

kazi11/actmon documentation built on May 20, 2019, 7:53 a.m.