Learn R Programming

pirouette (version 1.6.9)

is_dna_seq: Determine if the string is a lowercase DNA sequence of at least one base pair

Description

Determine if the string is a lowercase DNA sequence of at least one base pair

Usage

is_dna_seq(s)

Value

TRUE if the string is a lowercase DNA sequence of at least one base pair

Arguments

s

the string to be checked

Author

Richèl J.C. Bilderbeek

Examples

Run this code

# TRUE: valid and lowercase characters
is_dna_seq("acgt")

# FALSE: Must be lowercase
is_dna_seq("AGCT")

# FALSE: Must be only valid characters
is_dna_seq("xxxx")

# FALSE: Must have at least one nucleotide
is_dna_seq("")

Run the code above in your browser using DataLab