parse_bp: Parse a number of base pairs with optional units.

View source: R/data_manip_utils.R

parse_bpR Documentation

Parse a number of base pairs with optional units.

Description

Parse a number of base pairs with optional units.

Usage

parse_bp(size)

Arguments

size

A character vector representing a numbers of base pairs, optionally including units such as bp, kpb, etc.

Value

A numeric vector containing the parsed numbers of base pairs.

If any input cannot be parsed, an error is thrown.

See Also

si2f()

Examples


parse_bp(c("100", "100bp", "100 kbp", "1Mbp"))


DarwinAwardWinner/rctutils documentation built on July 22, 2022, 5:19 a.m.