-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfrom_DNAStringSet.Rd
More file actions
37 lines (36 loc) · 1.14 KB
/
from_DNAStringSet.Rd
File metadata and controls
37 lines (36 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/biostrings_utils.R
\name{from_DNAStringSet}
\alias{from_DNAStringSet}
\title{Convert a DNAStringSet to a named list of sequences}
\usage{
from_DNAStringSet(dna)
}
\arguments{
\item{dna}{A \code{DNAStringSet} object containing one or more DNA sequences.}
}
\value{
A named list of character strings, one element per sequence.
}
\description{
Converts a \code{\link[Biostrings]{DNAStringSet}} object to a named list of
character strings suitable for use with CGRphylo2 functions such as
\code{fastafile_new}, \code{create_meta}, and \code{parallelCGR}.
}
\details{
Bioconductor workflows commonly store DNA sequences as
\code{DNAStringSet} objects. This function bridges that format with
CGRphylo2's internal list representation, allowing seamless use of
Bioconductor data structures in CGR-based phylogenetic analysis.
}
\examples{
if (requireNamespace("Biostrings", quietly = TRUE)) {
dna <- Biostrings::DNAStringSet(c(
seq1 = "ATCGATCGATCGATCG",
seq2 = "GCTAGCTAGCTAGCTA"
))
seqs <- from_DNAStringSet(dna)
length(seqs) # 2
nchar(seqs[[1]]) # 16
}
}