cutAtMultSites: Cut character-vector at multiple sites

View source: R/cutAtMultSites.R

cutAtMultSitesR Documentation

Cut character-vector at multiple sites

Description

This function cuts character vector after 'cutAt' (ie keep the search subtsting 'cutAt', different to strsplit). Used for theoretical enzymatic digestion (eg in proteomics)

Usage

cutAtMultSites(y, cutAt)

Arguments

y

character vector (better if of length=1, otherwise one won't know which fragment stems from which input)

cutAt

(character) search subtsting, ie 'cutting rule'

Value

modified (ie cut) character vector

See Also

strsplit, nFragments0, nFragments

Examples

tmp <- "MSVSRTMEDSCELDLVYVTERIIAVSFPSTANEENFRSNLREVAQMLKSKHGGNYLLFNLSERRPDITKLHAKVLEFGWPDLHTPALEKI"
cutAtMultSites(c(tmp,"ojioRij"),c("R","K"))

wrMisc documentation built on Jan. 7, 2023, 1:27 a.m.