repeat_indicator: Handle repeat indicator of the key IDs

Description Usage Arguments Value Author(s) Examples

Description

The key IDs ('id' in @sinfo or @binder) should be unique throughout the samples and binders, in order to distinguish among them. So, any ids repeatedly used are amended by adding "*" and the digit indicating how many times the same ids have been employed ahead as a suffix (e.g. HPA0001, HPA0001*1) rm_repeat_indicator - Remove the additional suffix (repeat indicator)

make.unique_key_ids generate unique 'id's by adding the suffices. When necessary, the indicators previously attached are removed first.

Usage

1
2
3

Arguments

ids

a vector of the key IDs ('id' in @sinfo or @binder). It is by default converted to character.

Value

rm_repeat_indicator A vector of character of the 'id' after removal of the indicator

make.unique_key_ids A vector of character of cleaned 'id's with the suffix

Author(s)

Mun-Gwan Hong <mun-gwan.hong@scilifelab.se>

Examples

1
2
3
rm_repeat_indicator(c("HPA001", "HPA001*1"))

make.unique_key_ids(c("HPA001", "HPA003", "HPA001", "HPA001", "HPA003"))

Rundmus/BAf-R_package documentation built on May 18, 2020, 12:59 p.m.