This function shows the region slot from a DNAStringSet or an AAStringSet metadata information.

region(seq)

Arguments

seq

DNAStringSet or AAStringSet [mandatory]

Value

region IRanges object from metadata

See also

Author

Kristian K Ullrich

Examples

## load example sequence data
data(iupac, package="MSA2dist")
iupac.aa <- iupac |> cds2aa(shorten = TRUE)
## create region
region1 <- IRanges::IRanges(start=c(1,41), end=c(20,50))
## add region
iupac.aa <- iupac.aa |> addregion2string(region=region1)
iupac.aa |> region()
#> IRanges object with 2 ranges and 0 metadata columns:
#>           start       end     width
#>       <integer> <integer> <integer>
#>   [1]         1        20        20
#>   [2]        41        50        10