Learn R Programming

MassArray (version 1.24.0)

expandSequence: Expand nucleotide sequence

Description

Function to process shorthand form of a nucleotide sequence, where a given base pair followed by a number specifies a run of the indicated nucleotide for the specified length (ex: "A6TTCGA4")

Usage

expandSequence(sequence)

Arguments

sequence
Nucleotide sequence input as a character string

Value

Returns an expanded nucleotide sequence as a character string

Examples

Run this code
expandSequence("A6TTCGA4")
expandSequence("C10C10")
expandSequence("AT1CG")

Run the code above in your browser using DataLab