Learn R Programming

bioseq (version 0.1.4)

seq_nchar: Count the number of character in sequences

Description

Count the number of character in sequences

Usage

seq_nchar(x, gaps = TRUE)

Value

An integer vector giving the size of each sequence of x.

Arguments

x

a DNA, RNA or AA vector.

gaps

if FALSE gaps are ignored.

See Also

Other op-misc: seq_disambiguate_IUPAC(), seq_nseq(), seq_spellout(), seq_stat_gc(), seq_stat_prop()

Examples

Run this code

x <- dna(c("ATGCAGA", "GGR-----","TTGCCTAGKTGAACC"))
seq_nchar(x)
seq_nchar(x, gaps = FALSE)

Run the code above in your browser using DataLab