addFeature: Add a specific feature/attribute to the sampleInfo object.

Description Usage Arguments Value See Also Examples

View source: R/hiReadsProcessor.R

Description

Given a sampleInfo object, the function adds a new feature for the given samples & sectors.

Usage

1
2
3
4
5
6
7
addFeature(
  sampleInfo,
  sector = NULL,
  samplename = NULL,
  feature = NULL,
  value = NULL
)

Arguments

sampleInfo

sample information SimpleList object, which samples per sector/quadrant information along with other metadata.

sector

a vector or a specific sector to add the new feature(s) to. Default is NULL, in which case the sectors are searched from samplename parameter.

samplename

a character vector or a specific sample to add the new feature(s) to. Default is NULL.

feature

a string of naming the new feature to add for the defined samplename and sector.

value

named vector of samplenames & values which is assigned for the defined sector, samplename, and feature. Example: c("Sample1"="ACDTDASD")

Value

modified sampleInfo object with new feature(s) added.

See Also

findPrimers, extractSeqs, trimSeqs, extractFeature, getSectorsForSamples

Examples

1
2
3
4
5
6
7
8
9
load(file.path(system.file("data", package = "hiReadsProcessor"),
"FLX_seqProps.RData"))
extractFeature(seqProps, sector="2", 
samplename="Roth-MLV3p-CD4TMLVWell6-MseI", feature="metadata")
seqProps <- addFeature(seqProps, sector="2", 
samplename="Roth-MLV3p-CD4TMLVWell6-MseI", feature="foo", 
value=c("Roth-MLV3p-CD4TMLVWell6-MseI"="woo"))
extractFeature(seqProps, sector="2", 
samplename="Roth-MLV3p-CD4TMLVWell6-MseI", feature="metadata")

malnirav/hiReadsProcessor documentation built on July 29, 2021, 6:33 a.m.