Question: Outputting a multiple alignment to file error: could not find function write.XStringSet
0
gravatar for cmdcolin
2.5 years ago by
cmdcolin10
cmdcolin10 wrote:

```

    library(msa)
    library(Biostrings)

    x="ATGC"
    y="ATGA"
    z=msa(c(x,y), type="dna")
    write.XStringSet(z)

```

Error: could not find function "write.XStringSet"

msa • 485 views
ADD COMMENTlink modified 2.5 years ago by UBodenhofer250 • written 2.5 years ago by cmdcolin10
Answer: Outputting a multiple alignment to file error: could not find function write.XSt
2
gravatar for UBodenhofer
2.5 years ago by
UBodenhofer250
Johannes Kepler University, Linz, Austria
UBodenhofer250 wrote:

The correct name of the function is 'writeXStringSet' (without period). I don't recall precisely when the function name was changed, but I think it was several Bioconductor releases ago. The correct usage is the following:

writeXStringSet(unmasked(z), file="test.fasta")

The function 'unmasked' makes the conversion to an 'XStringSet' object; moreover, the file argument was missing in your example.

ADD COMMENTlink modified 2.5 years ago • written 2.5 years ago by UBodenhofer250
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 263 users visited in the last hour