This function finds all the combinations of sequences corresponding to a given vector of sequences with ambiguities (IUPAC codes).

seq_disambiguate_IUPAC(x)

Arguments

x

a DNA, RNA or AA vector

Value

A list of DNA, RNA or AA vectors (depending on the input) giving all possible combinations.

See also

Examples


x <- dna(c("AYCTGW", "CTTN"))
seq_disambiguate_IUPAC(x)
#> [[1]]
#> DNA vector of 4 sequences
#> >   ACCTGA
#> >   ATCTGA
#> >   ACCTGT
#> >   ATCTGT
#> 
#> [[2]]
#> DNA vector of 4 sequences
#> >   CTTA
#> >   CTTC
#> >   CTTG
#> >   CTTT
#> 

y <- seq_transcribe(x)
seq_disambiguate_IUPAC(y)
#> [[1]]
#> RNA vector of 4 sequences
#> >   ACCUGA
#> >   AUCUGA
#> >   ACCUGU
#> >   AUCUGU
#> 
#> [[2]]
#> RNA vector of 4 sequences
#> >   CUUA
#> >   CUUC
#> >   CUUG
#> >   CUUU
#> 

z <- aa("YJSNAALNX")
z <- seq_translate(y)
seq_disambiguate_IUPAC(z)
#> [[1]]
#> AA vector of 441 sequences
#> >   AA
#> >   CA
#> >   DA
#> >   EA
#> >   FA
#> >   GA
#> >   HA
#> >   IA
#> >   KA
#> >   LA
#> >   MA
#> >   NA
#> ... with 429 more sequences.
#> [[2]]
#> AA vector of 1 sequences
#> >   L
#>