Extract a region between two positions in sequences

seq_extract_position(x, position_in, position_out)

Arguments

x

a DNA, RNA or AA vector.

position_in

an integer giving the position where to start to extract.

position_out

an integer giving the position where to stop to extract.

Value

A vector of same class as x.

See also

Examples


x <- dna("ACGTTAGTGTAGCCGT", "CTCGAAATGA")
seq_extract_position(x, 3, 8)
#> DNA vector of 2 sequences
#> >   GTTAGT
#> >   CGAAAT